Jump to content

WinStartApp: Difference between revisions

From EDM2
WinStartApp created - more to do. how to link structs, how to link SAF constants. maybe PMI:Constant#SAF_...
 
m add links for SAF constants
Line 18: Line 18:
; flags - [[OS2 API:DataType:ULONG|ULONG]] - input :
; flags - [[OS2 API:DataType:ULONG|ULONG]] - input :
Zero for no flags or:
Zero for no flags or:
* SAF_BACKGROUND
* [[OS2 API:PMI:Constant#SAF_BACKGROUND|SAF_BACKGROUND]]
* SAF_INSTALLEDCMDLINE
* [[OS2 API:PMI:Constant#SAF_INSTALLEDCMDLINE|SAF_INSTALLEDCMDLINE]]
* SAF_MAXIMIZED
* [[OS2 API:PMI:Constant#SAF_MAXIMIZED|SAF_MAXIMIZED]]
* SAF_MINIMIZED
* [[OS2 API:PMI:Constant#SAF_MINIMIZED|SAF_MINIMIZED]]
* SAF_STARTCHILDAPP
* [[OS2 API:PMI:Constant#SAF_STARTCHILDAPP|SAF_STARTCHILDAPP]]


=== Constants ===
=== Constants ===

Revision as of 08:24, 6 February 2006

WinStartApp

WinStartApp(notifyHndl, progDetails, progParams, reserved, flags)

Execute a program.

Parameters

notifyHndl - HWND - input

The window notification handle or NULLHANDLE. If a window handle is passed, the system passes the WM_APPTERMINATENOTIFY message upon program exit.

progDetails - PROGDETAILS - input

The program list structure.

progParams - PSZ - input

NULL or the parameters for the program to be started. The layout is first, the program's exe name; the second, the space separated arguments.

reserved - PVOID - input

Start data. Reserved - pass NULL.

flags - ULONG - input

Zero for no flags or:

Constants

None

Returns

The invoked applications handle of type HAPP, or NULLHANDLE if an error occurred. Possible returns from WinGetLastError:

Module

Define (C/C++)

INCL_WINWINDOWMGR or INCL_WIN or INCL_PM

Export name/Ordinal

Calling conversion

Cdecl32

Example Code

HWND notifyHndl;
PROGDETAILS progDetails;
PSZ progParams;
PVOID reserved;
ULONG flags;
HAPP invokedHndl;
...
invokedHndl = WinStartApp(notifyHndl, progDetails, progParams, reserved, flags);
...

Related Functions

WinTerminateApp

Notes

OS Version Introduced