Beispiel #1
0
 private void SetInterface()
 {
     if (this.InvokeRequired)
     {
         SetInterfaceCallBack callback = new SetInterfaceCallBack(SetInterface);
         this.Invoke(callback, new object[] {  });
     }
     else
     {
         PersonalDataForm dataform = new PersonalDataForm(ConnectionClass.ClientTCP.isloged);
         this.panel1.Controls.Clear();
         this.panel1.Controls.Add(dataform);
     }
 }
Beispiel #2
0
        private void SetInterface(UserControl usercontrol)
        {
            Panel panel = (Panel)this.Parent;

            if (panel.InvokeRequired)
            {
                SetInterfaceCallBack callback = new SetInterfaceCallBack(SetInterface);
                this.Invoke(callback, new object[] { usercontrol });
            }
            else
            {
                panel.Controls.Clear();
                panel.Controls.Add(usercontrol);
            }
        }
Beispiel #3
0
        private void SetResponseInterface(string chanse, string chanse_to_have_nothing)
        {
            if (this.InvokeRequired)
            {
                SetInterfaceCallBack callback = new SetInterfaceCallBack(SetResponseInterface);
                this.Invoke(callback, new object[] { chanse, chanse_to_have_nothing });
            }
            else
            {
                Application.UseWaitCursor = false;
                ResponseUserControl usercontrol = new ResponseUserControl();
                usercontrol.SetCancer(chanse);
                usercontrol.SetNonCancer(chanse_to_have_nothing);
                usercontrol.SetAnimateCancer((int)double.Parse(chanse_to_have_nothing));


                Panel panel1 = (Panel)this.Parent;
                panel1.Controls.Clear();
                panel1.Controls.Add(usercontrol);
            }
        }