winapi - Running processes at different times stops events from working - C -


this question follows on answered question here

at first assumed had problem way creating events due handles openevent returning null, have managed find real cause not sure how go it.

basically use visual studio launch both process , b @ same time, in past openevent handle wouldn't work due process looking address of event fraction of second before process b had time make it.

my solution allow process b run before process a, fixing error.

the problem have process b reads events process , expect returns null handle when trying open events process a.

i creating events in wm_create message of both processes, furthermore create thread @ same time open/read/act upon events.

it seems if run them @ same time don't chance see each other, alternatively if run 1 before other 1 of them misses out , can't open handle.

can suggest solution?

thanks.

just replace openevent createevent. createevent open event instead of creating new 1 finds existing event name passed createevent.


Comments

Popular posts from this blog

javascript - Enclosure Memory Copies -

php - Replacing tags in braces, even nested tags, with regex -