Access denied on WaitForSingleObject on an event created from managed code
问题 How do I create a named event object in C# so that I can wait on it in separate C++ process? My simplified C# code of process A: EventWaitHandle evt = new EventWaitHandle(false, EventResetMode.AutoReset, "eventName"); EventWaitHandle.SignalAndWait(evt , <other event>); And simplified C++ code of process B: HANDLE hEvt = OpenEvent( EVENT_MODIFY_STATE | SYNCHRONIZE, // access FALSE, // do not inherit handle TEXT("eventName") ); if (hEvt == NULL) { printf("CreateEvent failed (%d)\n",