Click here to Skip to main content
16,005,241 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Threads and mutexes Pin
Matthew Faithfull17-Jun-07 0:45
Matthew Faithfull17-Jun-07 0:45 
GeneralRe: Threads and mutexes Pin
Cyrilix17-Jun-07 7:02
Cyrilix17-Jun-07 7:02 
GeneralRe: Threads and mutexes Pin
Matthew Faithfull17-Jun-07 10:11
Matthew Faithfull17-Jun-07 10:11 
GeneralRe: Threads and mutexes [modified] Pin
Cyrilix17-Jun-07 11:25
Cyrilix17-Jun-07 11:25 
GeneralRe: Threads and mutexes Pin
Bram van Kampen17-Jun-07 15:00
Bram van Kampen17-Jun-07 15:00 
GeneralRe: Threads and mutexes [modified] Pin
Cyrilix17-Jun-07 16:12
Cyrilix17-Jun-07 16:12 
GeneralRe: Threads and mutexes Pin
Matthew Faithfull17-Jun-07 22:23
Matthew Faithfull17-Jun-07 22:23 
GeneralRe: Threads and mutexes Pin
Bram van Kampen18-Jun-07 13:30
Bram van Kampen18-Jun-07 13:30 
Sorry for the Delay.

I do not know what your application is about, but observe as follows_-

Synchronisation Objects (Mutexex, CriticalSections et al) are there for one reason only, and that is to regulate access to shared resources (i.e. Data!)
A Process with threads which do not acess resources shared between threads can run quite successfully without any synchronisation objects. There are many good books available which discuss this subject. From what I gather from your reply, you seem to have an Outside Project which provides data sporadically. WaitForSingleObject(...) was invented for this! You create a Named AutoReset Event with CreateEvent(...) in the Process which generates the data.
When Data is Generated, you Set the Event.
In the program that has to process the data, you open an event of the same name! Then you wait for the event to occur (By set Event in the Other Program)to fire your Code.

Hope this is helpfullSmile | :)



LateNightsInNewry

NewsAboubt Barcode printing, VC++ master-hand Come in and help me. Pin
h_boy200816-Jun-07 20:46
h_boy200816-Jun-07 20:46 
AnswerRe: Aboubt Barcode printing, VC++ master-hand Come in and help me. Pin
Matthew Faithfull17-Jun-07 0:38
Matthew Faithfull17-Jun-07 0:38 
GeneralRe: Aboubt Barcode printing, VC++ master-hand Come in and help me. Pin
Matthew Faithfull18-Jun-07 1:44
Matthew Faithfull18-Jun-07 1:44 
Questionmsi setup project Pin
deeps_cute16-Jun-07 20:25
deeps_cute16-Jun-07 20:25 
QuestionFirst-chance exception ... access violation ... pointer issue Pin
moonraker92816-Jun-07 20:18
moonraker92816-Jun-07 20:18 
AnswerRe: First-chance exception ... access violation ... pointer issue Pin
Hans Dietrich16-Jun-07 20:33
mentorHans Dietrich16-Jun-07 20:33 
GeneralRe: First-chance exception ... access violation ... pointer issue Pin
moonraker92816-Jun-07 21:48
moonraker92816-Jun-07 21:48 
GeneralRe: First-chance exception ... access violation ... pointer issue Pin
Bram van Kampen18-Jun-07 13:38
Bram van Kampen18-Jun-07 13:38 
AnswerRe: First-chance exception ... access violation ... pointer issue Pin
Stephen Hewitt17-Jun-07 12:51
Stephen Hewitt17-Jun-07 12:51 
GeneralRe: First-chance exception ... access violation ... pointer issue Pin
Bram van Kampen18-Jun-07 13:49
Bram van Kampen18-Jun-07 13:49 
Questiondrawing 2D in C++ Pin
moonraker92816-Jun-07 19:33
moonraker92816-Jun-07 19:33 
AnswerRe: drawing 2D in C++ Pin
Cyrilix16-Jun-07 21:41
Cyrilix16-Jun-07 21:41 
GeneralRe: drawing 2D in C++ Pin
moonraker92816-Jun-07 22:01
moonraker92816-Jun-07 22:01 
GeneralRe: drawing 2D in C++ Pin
moonraker92816-Jun-07 22:51
moonraker92816-Jun-07 22:51 
GeneralRe: drawing 2D in C++ Pin
Cyrilix17-Jun-07 0:17
Cyrilix17-Jun-07 0:17 
QuestionCLSID Pin
Rose8116-Jun-07 16:14
Rose8116-Jun-07 16:14 
AnswerRe: CLSID Pin
Randor 18-Jun-07 4:06
professional Randor 18-Jun-07 4:06 

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.