05-10-12, 10:57 AM
كاتب الموضوع : silverlight
الأخوة الكرامفي المرفقات ملف اسمه غزة وهو عبارة عن ملف dll
عفوا لأول مرة لا اضع الكود لأنني ارغب ان يستخدم الملف كما هو وأيضا لا اريد أن يتم التعديل به
الملف عبارة عن ماسج بوكس علي طريقة الفيستا يمكنك ان تستخدمه داخل برامجك كما تشاء
وهذا الماسج بوكس يختلف قليلا عن الماسج بوكس العادي فانت تستطيع ان تقوم بتغبير لون التكست وايضا تم إضافة بعض الايقونات واخيرا انت تستطيع ان تجعل لون البوكس نفسه مختلفا لك ان تختار ما تشاء من الألوان
الملف يمكن استخدامه فقط مع نسخة الفيجوال دوت نت 2005 وبالطبع نسخة 2008
كيف يتم إضافة الملف المرفق الي برامجك
أولا عليك ان تقوم بفك الملف المرفق وهو ملف مضغوط بامتداد rar
ثانيا من داخل الفيجوال استوديو و من قائمة Project عليك أن تختار Add Reference ثم تختار Browse ثم تذهب الي الملف وتختاره وهنا سيتم إضافته الي مشروعك مباشرة
أما عن كيف تستخدم الكود فإن ذلك يتم كالتالي
كل ما عليك أن تستخدم جملة Imports Ghaza ويتم ذلك كالتالي
كود :
Imports Ghaza
Public Class Form1
End Class
ثم بعد ذلك عليك ان تستخدم الكود بالشكل التالي
بأن تستخدم جملة MsgBoxGhazaInHeart مثلما تستخدم جملة MessageBox العادية
كود :
Imports Ghaza
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'
'
MsgBoxGhazaInHeart.Show("Exit Ghaza", Me.Text, MsgBoxGhazaInHeart.MessageBoxButtons.OK, MsgBoxGhazaInHeart.MessageBoxIcon.Exit)
'
'
MsgBoxGhazaInHeart.BoxColor = Color.Green
MsgBoxGhazaInHeart.BoxGradientColor = Color.Lime
MsgBoxGhazaInHeart.BoxTextColor = Color.Green
MsgBoxGhazaInHeart.Show("Exit Ghaza", Me.Text, MsgBoxGhazaInHeart.MessageBoxButtons.AbortRetryIgnore, MsgBoxGhazaInHeart.MessageBoxIcon.Globe)
'
'
MsgBoxGhazaInHeart.BoxColor = Color.DarkMagenta
MsgBoxGhazaInHeart.BoxGradientColor = Color.Violet
MsgBoxGhazaInHeart.BoxTextColor = Color.Blue
MsgBoxGhazaInHeart.Show("Exit Ghaza", Me.Text, MsgBoxGhazaInHeart.MessageBoxButtons.YesNo, MsgBoxGhazaInHeart.MessageBoxIcon.Warning)
'
'
MsgBoxGhazaInHeart.BoxColor = Color.Maroon
MsgBoxGhazaInHeart.BoxGradientColor = Color.DarkOrange
MsgBoxGhazaInHeart.BoxTextColor = Color.Brown
MsgBoxGhazaInHeart.Show("Exit Ghaza", Me.Text, MsgBoxGhazaInHeart.MessageBoxButtons.RetryCancel, MsgBoxGhazaInHeart.MessageBoxIcon.NetWork)
'
'
'
MsgBoxGhazaInHeart.BoxColor = Color.Red
MsgBoxGhazaInHeart.BoxGradientColor = Color.Red
MsgBoxGhazaInHeart.BoxTextColor = Color.Red
MsgBoxGhazaInHeart.Show("Exit Ghaza", Me.Text, MsgBoxGhazaInHeart.MessageBoxButtons.OKCancel, MsgBoxGhazaInHeart.MessageBoxIcon.NetWork)
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim m_Result As DialogResult
MsgBoxGhazaInHeart.BoxColor = Color.Black
MsgBoxGhazaInHeart.BoxGradientColor = Color.DarkOrange
MsgBoxGhazaInHeart.BoxTextColor = Color.Red
m_Result = MsgBoxGhazaInHeart.Show("Press the Key You Want", "Test", MsgBoxGhazaInHeart.MessageBoxButtons.YesNoCancel, MsgBoxGhazaInHeart.MessageBoxIcon.Camera)
If m_Result = DialogResult.Yes Then
Me.Text = "You Pressed : " & DialogResult.Yes.ToString & " " & "Button"
ElseIf m_Result = DialogResult.No Then
Me.Text = "You Pressed : " & DialogResult.No.ToString & " " & "Button"
ElseIf m_Result = DialogResult.Cancel Then
Me.Text = "You Pressed : " & DialogResult.Cancel.ToString & " " & "Button"
End If
End Sub
End Class
اتمني أن تستخدموه حتي لا ننسي غزة او غيرها وأعتقد انه سيعجبكم
ملحوظه:
من يجد اي Bug به عليه ترك رساله لي
من لديهم نسخة فيستا علي اجهزة الكمبيوتر رجاء أن تجربوه وتبلغوني كيفية شكل الماسج في بيئة الفيستا
بالتوفيق
أخوكم عمر