Click here to Skip to main content
15,894,405 members
Home / Discussions / C#
   

C#

 
QuestionNot All Code Paths Return A Value??? Pin
dbenisch31-Jan-06 13:49
dbenisch31-Jan-06 13:49 
AnswerRe: Not All Code Paths Return A Value??? Pin
M@dHatter31-Jan-06 13:54
M@dHatter31-Jan-06 13:54 
GeneralRe: Not All Code Paths Return A Value??? Pin
dbenisch31-Jan-06 14:27
dbenisch31-Jan-06 14:27 
GeneralRe: Not All Code Paths Return A Value??? Pin
Christian Graus31-Jan-06 14:28
protectorChristian Graus31-Jan-06 14:28 
QuestionAccessing Access DataBase Pin
aPerfectCircle31-Jan-06 13:12
aPerfectCircle31-Jan-06 13:12 
AnswerRe: Accessing Access DataBase Pin
Kodanda Pani31-Jan-06 18:56
Kodanda Pani31-Jan-06 18:56 
AnswerRe: Accessing Access DataBase Pin
Navas.M31-Jan-06 20:24
Navas.M31-Jan-06 20:24 
Questionthread safe calls Pin
Manu_8131-Jan-06 12:57
Manu_8131-Jan-06 12:57 
private void HomeFrom_Activated(object sender, System.EventArgs e)<br />
		{<br />
			<br />
				<br />
			PrimeInfoThread pTh = new PrimeInfoThread(this.pictureBox1,this.panel4,this.button1,this.button3,this.SLabel);<br />
			Thread t = new Thread(new ThreadStart(pTh.ThreadProc));<br />
			t.Start();			<br />
			//t.Join();<br />
			<br />
		}<br />
<br />
...<br />
public class PrimeInfoThread<br />
	{<br />
		private System.Windows.Forms.PictureBox hPic ;<br />
		private System.Windows.Forms.Panel hPan ;<br />
		private System.Windows.Forms.Button but1 ;<br />
		private System.Windows.Forms.Button but2 ;<br />
		private System.Windows.Forms.Label slab ;<br />
<br />
		// The constructor <br />
		public PrimeInfoThread(System.Windows.Forms.PictureBox hP,<br />
								System.Windows.Forms.Panel hpanel,<br />
								System.Windows.Forms.Button b1,<br />
								System.Windows.Forms.Button b2,<br />
								System.Windows.Forms.Label Sl) <br />
		{<br />
			hPic = hP;<br />
			hPan = hpanel;<br />
			but1 = b1;<br />
			but2 = b2;<br />
			slab = Sl;<br />
		}<br />
<br />
		public void ThreadProc() <br />
		{<br />
			EnumGetEDID InitEnumObj = new EnumGetEDID();<br />
			InitEnumObj.AppInitEnum(slab);	<br />
			hPic.Hide();<br />
			hPan.Hide();<br />
			but1.Show();<br />
			but2.Show();<br />
			<br />
		}<br />
<br />
	}<br />


I have the above code where I modify my form controls in another thread.
Is is safe to do like this. How to do this using thread-safe calls/delegates.
Thanks.
AnswerRe: thread safe calls Pin
kasik31-Jan-06 13:07
kasik31-Jan-06 13:07 
AnswerRe: thread safe calls Pin
Shann31-Jan-06 23:32
Shann31-Jan-06 23:32 
QuestionError Icon on custom form Pin
theFrenchHornet31-Jan-06 12:13
theFrenchHornet31-Jan-06 12:13 
AnswerRe: Error Icon on custom form Pin
kasik31-Jan-06 12:51
kasik31-Jan-06 12:51 
GeneralRe: Error Icon on custom form Pin
theFrenchHornet31-Jan-06 16:23
theFrenchHornet31-Jan-06 16:23 
Questiontuff deployments projects. Pin
ranzask31-Jan-06 11:37
ranzask31-Jan-06 11:37 
QuestionSocket Help Pin
DocH0liday31-Jan-06 11:06
DocH0liday31-Jan-06 11:06 
QuestionHow can I Give the application referenced by a Process object Focus Pin
Dan Neely31-Jan-06 11:04
Dan Neely31-Jan-06 11:04 
Questiontimeout in second call webservice???? Pin
leonvanrooijen31-Jan-06 10:04
leonvanrooijen31-Jan-06 10:04 
Questionmy application with graphic Pin
Sasuko31-Jan-06 10:02
Sasuko31-Jan-06 10:02 
QuestionThreading Pin
nc3b31-Jan-06 9:48
nc3b31-Jan-06 9:48 
AnswerRe: Threading Pin
Le centriste31-Jan-06 10:13
Le centriste31-Jan-06 10:13 
GeneralRe: Threading Pin
nc3b31-Jan-06 10:15
nc3b31-Jan-06 10:15 
Questiondo I need a lience to use word.dll in a commercial product Pin
Agyeman31-Jan-06 9:38
Agyeman31-Jan-06 9:38 
AnswerRe: do I need a lience to use word.dll in a commercial product Pin
Praveen Nayak31-Jan-06 17:20
Praveen Nayak31-Jan-06 17:20 
QuestionBinary Data &amp;amp; .Net Sockets, URGENT Pin
John Gouda31-Jan-06 9:27
John Gouda31-Jan-06 9:27 
QuestionHow does 1 thread multiply into 3 threads??? Pin
WetRivrRat31-Jan-06 8:27
WetRivrRat31-Jan-06 8:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.