Creates and starts a new INtime iwin32 process. It is supported both in the INtime environment and in Windows. In addition to creating a process, it also creates a thread object.
BOOLEAN RtCreateProcess( LPCTSTR lpApplicationName, LPTSTR lpCommandLine, LPSECURITY_ATTRIBUTES lpProcessAttributes, LPSECURITY_ATTRIBUTES lpThreadAttributes, BOOLEAN bInheritHandles, DWORD dwCreationFlags, LPVOID lpEnvironment, LPCTSTR lpCurrentDirectory, LPSTARTUPINFO lpStartupInfo, LPPROCESS_INFORMATION lpProcessInformation );
lpApplicationName
The string can specify the full path and filename of the module to execute or it can specify a partial path and filename.
lpCommandLine
lpProcessAttributes
lpThreadAttributes
bInheritHandles
dwCreationFlags
NTX_PROC_XM
NTX_PROC_NOTXM
lpEnvironment
lpCurrentDirectory
lpStartupInfo
lpProcessInformation
Returns a non-zero value on success, or FALSE on failure. The status code may be obtained by calling GetLastError().
If lpProcessInformation is not NULL, the HANDLE of the new process returns; it should be closed when no longer required.
Note: if the process being loaded in not an iwin32 process (that is, it was not built with the iwin32 library), then the PROCESS_INFORMATION structure is not relevant. You shoudl specifiy NULL for this parameter, or else the call will fail with a status of ERROR_INVALID_HANDLE.
The thread's initial stack size is described in the image header of the specified program's executable file.
The thread begins execution at the image's entry point.
The process is assigned a 32-bit process identifier. The identifier is valid until the process terminates. It can be used to identify the process, or specified in OpenProcess to open a handle to the process.
The initial thread in the process is also assigned a 32-bit thread identifier. The identifier is valid until the thread terminates and can be used to uniquely identify the thread within the system. These identifiers are returned in the _PROCESS_INFORMATION structure.
The created process remains in the system until all threads within the process terminate and all handles to the process and its threads close through calls to CloseHandle.
The handles for the process and the main thread must be closed through calls to CloseHandle. If these handles are not needed, close them immediately after the process is created.
Versions | Defined in | Include | Link to |
---|---|---|---|
INtime 3.0 | intime/rt/include/iwin32.h | iwin32.h | iwin32.lib |
Notes