Click here to Skip to main content
15,917,060 members
Home / Discussions / C#
   

C#

 
GeneralRe: Finding a Number in a string Pin
Le centriste11-Jan-06 4:35
Le centriste11-Jan-06 4:35 
AnswerRe: Finding a Number in a string Pin
User 665811-Jan-06 4:09
User 665811-Jan-06 4:09 
GeneralRe: Finding a Number in a string Pin
alvinjv11-Jan-06 5:10
alvinjv11-Jan-06 5:10 
GeneralRe: Finding a Number in a string Pin
User 665811-Jan-06 7:15
User 665811-Jan-06 7:15 
QuestionWorker Threads Pin
akshayswaroop11-Jan-06 2:50
akshayswaroop11-Jan-06 2:50 
AnswerRe: Worker Threads Pin
lmoelleb11-Jan-06 3:09
lmoelleb11-Jan-06 3:09 
GeneralRe: Worker Threads Pin
akshayswaroop11-Jan-06 20:31
akshayswaroop11-Jan-06 20:31 
GeneralRe: Worker Threads Pin
lmoelleb11-Jan-06 20:54
lmoelleb11-Jan-06 20:54 
I understand what you want, but I do not see what additional information you need.

Create a variable (or queue to handle multiple request serially) protected by locks (or using a syncronized queue).
Thread 1 does whatever it needs, then insert the "task" in the variable or queue. Once it is inserted it sets the event.

Thread 2 simply waits for the event to be raized. Once raized it takes the work object and do whatever it needs to do. For a queue, keep looping until all data is done, then wait for the event. For the variable you might need an extra event from thread 2 to inform thread 1 that it can override the variable - all in all the queue is simpler.

Obviously you have to be careful with timing.
GeneralRe: Worker Threads Pin
akshayswaroop12-Jan-06 3:09
akshayswaroop12-Jan-06 3:09 
QuestionUnable to Load XML Pin
Samy Lahur11-Jan-06 2:32
Samy Lahur11-Jan-06 2:32 
AnswerRe: Unable to Load XML Pin
lmoelleb11-Jan-06 3:14
lmoelleb11-Jan-06 3:14 
GeneralRe: Unable to Load XML Pin
Samy Lahur11-Jan-06 4:16
Samy Lahur11-Jan-06 4:16 
AnswerRe: Unable to Load XML Pin
KaptinKrunch11-Jan-06 3:15
KaptinKrunch11-Jan-06 3:15 
GeneralRe: Unable to Load XML Pin
Samy Lahur11-Jan-06 4:15
Samy Lahur11-Jan-06 4:15 
Question.parse vs casting Pin
fmardani11-Jan-06 2:27
fmardani11-Jan-06 2:27 
AnswerRe: .parse vs casting Pin
User 665811-Jan-06 3:03
User 665811-Jan-06 3:03 
AnswerRe: .parse vs casting Pin
Curtis Schlak.11-Jan-06 3:25
Curtis Schlak.11-Jan-06 3:25 
AnswerRe: .parse vs casting Pin
Guffa11-Jan-06 11:17
Guffa11-Jan-06 11:17 
QuestionHow to get the IP address of the current host? Pin
bouli11-Jan-06 1:13
bouli11-Jan-06 1:13 
AnswerRe: How to get the IP address of the current host? Pin
mikailcetinkaya11-Jan-06 9:09
mikailcetinkaya11-Jan-06 9:09 
GeneralRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 9:34
mveDave Kreskowiak11-Jan-06 9:34 
AnswerRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 9:32
mveDave Kreskowiak11-Jan-06 9:32 
GeneralRe: How to get the IP address of the current host? Pin
bouli11-Jan-06 10:15
bouli11-Jan-06 10:15 
GeneralRe: How to get the IP address of the current host? Pin
Dave Kreskowiak11-Jan-06 10:53
mveDave Kreskowiak11-Jan-06 10:53 
QuestionFinger print scanner Access in C# Pin
Ckhurana11-Jan-06 0:51
Ckhurana11-Jan-06 0:51 

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.