StdOutHndl function

 

Usage:

Handle??? = StdOutHndl

 

Legacy Syntax:

Handle??? = GETSTDOUT

 

Pseudo-object Syntax:

Handle??? = CON.GETSTDOUT

 

Gets the Windows API handle of the standard output device.

 

It is normally only necessary to get this handle if you wish to use API functions. The returned handle can also be used with the OPEN HANDLE statement, if you wish to treat standard output as a file.

 

If not redirected, the standard output handle is equal to ConPageHndl(1) but redirection will cause the standard output handle to be different. You can use ConStdOut to determine if redirection is in effect.

 

Conversion:

 

#IF %DEF(%PB_CC32)

  Handle??? = GETSTDOUT

#ELSE

  Handle??? = StdOutHndl

#ENDIF

 

CON.GETSTDOUT or CONSOLE.GETSTDOUT may be substituted for GETSTDOUT in programs written for PB/CC 6. The syntax " ... TO Handle???" may be used instead of "Handle??? = ..."

 

See Also: ConStdOut, ConPageHndl