Click here to Skip to main content
15,905,028 members
Home / Discussions / C#
   

C#

 
AnswerRe: How to implement abort functionality Pin
Jun Du11-Jun-06 2:13
Jun Du11-Jun-06 2:13 
QuestionHow to Specify DialogResult Pin
Richard Andrew x6410-Jun-06 18:28
professionalRichard Andrew x6410-Jun-06 18:28 
AnswerRe: How to Specify DialogResult Pin
Super Lloyd10-Jun-06 20:16
Super Lloyd10-Jun-06 20:16 
GeneralRe: How to Specify DialogResult Pin
Richard Andrew x6410-Jun-06 20:17
professionalRichard Andrew x6410-Jun-06 20:17 
GeneralRe: How to Specify DialogResult Pin
Super Lloyd10-Jun-06 20:46
Super Lloyd10-Jun-06 20:46 
Questionsqlconnection by_IP Pin
Mohammed Elkholy10-Jun-06 11:09
Mohammed Elkholy10-Jun-06 11:09 
AnswerRe: sqlconnection by_IP Pin
Guffa10-Jun-06 11:19
Guffa10-Jun-06 11:19 
Questionrunning two UI threads in same application Pin
venkyp10-Jun-06 10:43
venkyp10-Jun-06 10:43 
Hi This is my first experiment with c#. I am making an application that must have two threads. One should handle the main dialog and it's message loop. I am starting the other thread in main method and this thread creates another independent dialog(which is an animated tasbar notification). But I should also be able to handle events(button clicks for example) in this second dialog. But my second thread is taking control immediately after showing the dialog and I cannot find a way to transfer control to the message loop of the second dialog. The following code snippet makes clear of what I am talking of.
<br />
public static void NotificationThreadProc()<br />
		{<br />
			Console.WriteLine("Inside notification thread");<br />
			Notification n = new Notification();<br />
			n.showNotification("Hello");<br />
			<br />
			Thread.Sleep(2000);<br />
			n.hideNotification();<br />
			n.Close();<br />
			return;<br />
		}<br />


NotificationThreadProc is the procedure name I passed as a parameter to ThreadStart(). Notification is my second dialog. Show notification simply runs a for loop resulting in animating the dialog to look like a taskbar notification. I need a button inside this notification and I need an event handler to be invoked when I press this button. But since the thread that created this control is busy sleeping. How can I make this Notification thread listen to events from inside the Notification dialog? Please help..Any small clue is highly appreciated.

Thanks in Advance,
venkat.
Questiontext files Pin
rcwoods10-Jun-06 9:13
rcwoods10-Jun-06 9:13 
AnswerRe: text files Pin
Guffa10-Jun-06 11:06
Guffa10-Jun-06 11:06 
QuestionHow can I alter the property of the main form control from a secondary form? Pin
AngryC10-Jun-06 7:45
AngryC10-Jun-06 7:45 
AnswerRe: How can I alter the property of the main form control from a secondary form? Pin
led mike10-Jun-06 17:06
led mike10-Jun-06 17:06 
AnswerRe: How can I alter the property of the main form control from a secondary form? Pin
engsrini10-Jun-06 20:48
engsrini10-Jun-06 20:48 
GeneralRe: How can I alter the property of the main form control from a secondary form? Pin
AngryC11-Jun-06 11:58
AngryC11-Jun-06 11:58 
GeneralRe: How can I alter the property of the main form control from a secondary form? Pin
engsrini20-Jun-06 8:03
engsrini20-Jun-06 8:03 
QuestionIf an exception is thrown inside a lock {...} [modified] Pin
Marc Clifton10-Jun-06 7:24
mvaMarc Clifton10-Jun-06 7:24 
AnswerRe: If an exception is thrown inside a lock {...} [modified] Pin
Ravi Bhavnani10-Jun-06 9:42
professionalRavi Bhavnani10-Jun-06 9:42 
GeneralRe: calculating diff between 2 dates Pin
Guffa10-Jun-06 8:49
Guffa10-Jun-06 8:49 
GeneralRe: calculating diff between 2 dates Pin
Yustme10-Jun-06 8:50
Yustme10-Jun-06 8:50 
AnswerRe: calculating diff between 2 dates Pin
Guffa10-Jun-06 11:16
Guffa10-Jun-06 11:16 
AnswerRe: calculating diff between 2 dates Pin
Guffa10-Jun-06 22:27
Guffa10-Jun-06 22:27 
GeneralRe: calculating diff between 2 dates [modified] Pin
Yustme11-Jun-06 0:16
Yustme11-Jun-06 0:16 
QuestionNat Traversal Problem Pin
snouto10-Jun-06 6:46
snouto10-Jun-06 6:46 
QuestionProblem in UnmanagedTypes Pin
EngHafez10-Jun-06 5:28
EngHafez10-Jun-06 5:28 
QuestionParse text file and load data to text boxes Pin
Saamir10-Jun-06 4:57
Saamir10-Jun-06 4:57 

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.