Пример #1
0
 private void TriggerShowMessageEvent(ShowMessageEventArgs e)
 {
     if (ShowMessageEvent != null)
     {
         ShowMessageEvent(this, e);
     }
 }
Пример #2
0
        private void HWndCtrl_ShowMessageEvent(object sender, ShowMessageEventArgs e)
        {
            switch (e.MessageType)
            {
            case MessageType.MouseMessage:
                if (lblMouseMessage.Visible == false)
                {
                    lblMouseMessage.Visible = true;
                }
                lblMouseMessage.Text = hWndCtrl.MousePosMessage;
                break;

            case MessageType.ShowOk:
                if (labelResult.Visible == false)
                {
                    labelResult.Visible = true;
                }
                labelResult.BackColor = Color.Green;
                labelResult.Text      = "OK";
                break;

            case MessageType.ShowNg:
                if (labelResult.Visible == false)
                {
                    labelResult.Visible = true;
                }
                labelResult.BackColor = Color.Red;
                labelResult.Text      = "NG";
                break;

            default:
                break;
            }
        }