win32api.SetStdHandle

SetStdHandle(handle, handle)

Set the handle for the standard input, standard output, or standard error device

Parameters

handle : int

input, output, or error device

handle : PyHANDLE/int

A previously opened handle to be a standard handle