ConsoleAttributes.GetStdHandle Method

Mentalis.org Proxy

Mentalis.org Proxy Documentation

ConsoleAttributes.GetStdHandle Method 

The GetStdHandle function returns a handle for the standard input, standard output, or standard error device.

[Visual Basic]Friend Shared Function GetStdHandle( _
   ByVal nStdHandle As Integer _
) As Integer
[C#]
internal static int GetStdHandle(
   int nStdHandle
);

Parameters

nStdHandle
Specifies the device for which to return the handle. This parameter can have one of the following values:
  • STD_INPUT_HANDLEStandard input handle.
  • STD_OUTPUT_HANDLEStandard output handle.
  • STD_ERROR_HANDLEStandard error handle.

Return Value

If the function succeeds, the return value is a handle to the specified device.

If the function fails, the return value is the INVALID_HANDLE_VALUE flag. To get extended error information, call GetLastError.

See Also

ConsoleAttributes Class | ConsoleAttributes Members | Org.Mentalis.Utilities.ConsoleAttributes Namespace