Important: The information in this document is obsolete and should not be used for new development.
SetFrontProcessfunction to set the front process.
FUNCTION SetFrontProcess (PSN: ProcessSerialNumber): OSErr;
- The process serial number of the process you want to move to the foreground. This number should be a valid process serial number returned from
GetCurrentProcess, or a high-level event. You can also use the constant
kCurrentProcessto refer to the current process.
SetFrontProcessfunction schedules the specified process to move to the foreground. The specified process moves to the foreground after the current foreground process makes a subsequent call to
If the specified process serial number is invalid or if the specified process is a background-only application,
SetFrontProcessreturns a nonzero result code and does not change the current foreground process.
If a modal dialog box is the frontmost window, the specified process remains in the background until the user dismisses the modal dialog box.
ASSEMBLY-LANGUAGE INFORMATIONThe trap macro and routine selector for the
Trap macro Selector _OSDispatch $003B
SPECIAL CONSIDERATIONSDo not call
noErr 0 No error procNotFound -600 Process with specified process serial number doesn't exist or process is suspended by high-level debugger appIsDaemon -606 Specified process runs only in the background