private void EntryEndColor_Click(object sender, EventArgs e)
 {
     if (ChooseColor.ShowDialog() == DialogResult.Cancel)
     {
         return;
     }
     EntryEndColor.BackColor = ChooseColor.Color;
 }
Beispiel #2
0
        private void ColorBox_MouseClick(object sender, MouseEventArgs e)
        {
            ChooseColor.ShowDialog();
            ColorBox.BackColor = ChooseColor.Color;
            Bcolor             = ChooseColor.Color;
            textBox1.ForeColor = Bcolor;
            String temp = System.Drawing.ColorTranslator.ToHtml(Bcolor);

            c.Send("0." + Username + "已更改顏色為./cd." + temp + "." + Bcolor);
        }
Beispiel #3
0
 private void Color_TextSet(Control ctrl)
 {
     if (ChooseColor.ShowDialog() == DialogResult.OK)
     {
         if (ChooseColor.Color == Color.Black && ctrl.Name != "pictureBox3")
         {
             AlertBox.ShowDialog("Sorry.....:( We r not allow u to set the Black Color.", AlertBox.AlertType.warning, false);
             AlertBox.ShowDialog("Please try another color.", AlertBox.AlertType.information, true);
         }
         else
         {
             ctrl.BackColor = ChooseColor.Color;
         }
     }
 }