Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Blinker 5.10 Online Reference - <b> swpgetpid() / swpgetpidbas()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 SWPGETPID() / SWPGETPIDBAS()
------------------------------------------------------------------------------
 Purpose:
 Determine if a given program is a parent to the current program.

 Syntax:
 lValue = SWPGETPID(cIdString)

 Parameters:
 cIdString  Program ID string

 Returns:
 Logical value indicating whether the passed string was set as a program
 ID by a parent process.

 Description:
 Determine if cIdString was a parent (at any previous level) of the
 currently executing application. cIdString must be 31 characters or less,
 or the function will return a false value. The string must exactly match
 an Id set by a parent program using a call to SWPSETPID(). This can be
 useful in preventing two copies of the same application from being executed.

 Example:
 IdStr = "Test Program"                                                      
 IF SWPGETPID(IdStr)                                                         
    ? IdStr + " is already executing!"                                       
    QUIT                                                                     
 ENDIF                                                                       
 SWPSETPID(IdStr)                                                            

See Also: SWPADDSTR() / SWPADDSTRBAS() SWPGETSTR() / SWPGETSTRBAS() SWPSETPID() / SWPSETPIDBAS() SWPSETSTR() / SWPSETSTRBAS()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson