منتدى فيجوال بيسك لكل العرب | منتدى المبرمجين العرب

نسخة كاملة : كيف عمل load لى ملف NoteBad
أنت حالياً تتصفح نسخة خفيفة من المنتدى . مشاهدة نسخة كاملة مع جميع الأشكال الجمالية .
كود :
Label1.ForeColor = Label2.ForeColor
  If Label2.Text = "AliceBlue" Then
            Label2.ForeColor = Color.AliceBlue
        End If
        If Label2.Text = "AntiqueWhite" Then
            Label2.ForeColor = Color.AntiqueWhite
        End If
        If Label2.Text = "Aqua" Then
            Label2.ForeColor = Color.Aqua
        End If
        If Label2.Text = "Aquamarine" Then
            Label2.ForeColor = Color.Aquamarine
        End If
        If Label2.Text = "Azure" Then
            Label2.ForeColor = Color.Azure
        End If
        If Label2.Text = "Beige" Then
            Label2.ForeColor = Color.Beige
        End If
        If Label2.Text = "Bisque" Then
            Label2.ForeColor = Color.Bisque
        End If
        If Label2.Text = "Beige" Then
            Label2.ForeColor = Color.Beige
        End If
        If Label2.Text = "Bisque" Then
            Label2.ForeColor = Color.Bisque
        End If
        If Label2.Text = "Black" Then
            Label2.ForeColor = Color.Black
        End If
        If Label2.Text = "BlanchedAlmond" Then
            Label2.ForeColor = Color.BlanchedAlmond
        End If
        If Label2.Text = "Blue" Then
            Label2.ForeColor = Color.Blue
        End If
هل توجد طريقه اسهل من هذه يعنى لو كتبت اسم الون فى ملف Notepad على النت يتم تغير الون حسب الاسم
اخى الكريم يكفيك هذا الكود للاستغناء عن كل هذه الاكواد التى كتبتها
Label2.ForeColor = Color.FromName(Label1.Text)
وبالتوفيق ان شاء الله