INtime SDK Help
CreateEvent, RtCreateEvent (iwin32)
INtime SDK v7.1 > About INtime > Alternate APIs > iwin32 API > iwin32 API > CreateEvent, RtCreateEvent (iwin32)

Creates or opens an event.

HANDLE CreateEvent(
    LPSECURITY_ATTRIBUTES lpEventAttributes,
    BOOLEAN ManualReset,
    BOOLEAN bInitialState,
    LPCTSTR lpName
);

HANDLE RtCreateEvent(
    LPSECURITY_ATTRIBUTES lpEventAttributes,
    BOOLEAN ManualReset,
    BOOLEAN bInitialState,
    LPCTSTR lpName
);

Parameters

lpEventAttributes
Ignored; set to NULL.
ManualReset
Boolean event type:
TRUE
Use ResetEvent to manually reset the event to the non-signaled state.
FALSE
The system automatically resets the event after a single waiting thread is released.
bInitialState
Specifies the initial event state:
TRUE
Signaled.
FALSE
Non-signaled.
lpName
Pointer to a null-terminated string that specifies the event object's name. The name is limited to MAX_PATH characters and can contain any character except the backslash path-separator character (\). Name comparison is case sensitive. Values include:
NULL
The event object is created without a name.
Matches an existing named event object
Ignores the ManualReset and bInitialState parameters because they were already set by the creation process.
Matches the name of an existing mutex, semaphore, or shared memory object
The function fails and GetLastError returns ERROR_INVALID_HANDLE. This occurs because these objects share the same name space.

Remarks

You can also use RtCreateEvent from a Windows application to create an iwin32 object.

Return Values

Handle of the event object
Success.
NULL
Failure.

For extended error information, see GetLastError.

Requirements

Versions Defined in Include Link to
INtime 3.0 intime/rt/include/iwin32.h
intime/rt/include/winbase.h
iwin32.h
windows.h
iwin32.lib

See Also

RtOpenEvent (iwin32x), RtPulseEvent (iwin32x), RtResetEvent (iwin32x), RtSetEvent (iwin32x), iwin32 API, iwin32 Overview