M
MikeY
Hi Everyone,
I'm lookig for a way around retrieving my information, with out having to
take it to another method.
I have two buttons "YES" "NO" on a custum control and I want to retrieve the
returned info of yes or no in the same method I called up the control
instead of sending it to another method for extraction. My code is as
follows:
MSG_YesNo MSGYesNo = new MSG_YesNo();
MSGYesNo.Location = new System.Drawing.Point(280, 30);
MSGYesNo.Show();
this.Controls.Add(MSGYesNo);
MSGYesNo.BringToFront();
-----Origional way-----
MSGYesNo.Click += new System.EventHandler(MSGYesNo.On_Click);
-----Prefered way, but doesn't work-----
string Response = MSGYesNo.Click += new
System.EventHandler(MSGYesNo.On_Click);
MessageBox.Show(Response);
Thank you all in advance,
MikeY
I'm lookig for a way around retrieving my information, with out having to
take it to another method.
I have two buttons "YES" "NO" on a custum control and I want to retrieve the
returned info of yes or no in the same method I called up the control
instead of sending it to another method for extraction. My code is as
follows:
MSG_YesNo MSGYesNo = new MSG_YesNo();
MSGYesNo.Location = new System.Drawing.Point(280, 30);
MSGYesNo.Show();
this.Controls.Add(MSGYesNo);
MSGYesNo.BringToFront();
-----Origional way-----
MSGYesNo.Click += new System.EventHandler(MSGYesNo.On_Click);
-----Prefered way, but doesn't work-----
string Response = MSGYesNo.Click += new
System.EventHandler(MSGYesNo.On_Click);
MessageBox.Show(Response);
Thank you all in advance,
MikeY