boolean AllocConsole()
Allocates a new console for the calling process.
true
if successful - if false
then use GetLastError()
to get extended error information
boolean FreeConsole()
Detaches the calling process from its console
true
if successful - if false
then use GetLastError()
to get extended error information
boolean AttachConsole(int dwProcessId)
Attaches the calling process to the console of the specified process
dwProcessId
- The identifier of the process whose console is to be used. Can be either the process ID or the special ATTACH_PARENT_PROCESS
value to indicate the console of the parent of the current process.
true
if successful - if false
then use GetLastError()
to get extended error information
Flushes the console input buffer. All input records currently in the input buffer are discarded.
hConsoleInput
- A handle to the console input buffer. The handle must have the GENERIC_WRITE access right.
true
if successful - if false
then use GetLastError()
to get extended error information
boolean GenerateConsoleCtrlEvent(int dwCtrlEvent, int dwProcessGroupId)
Sends a specified signal to a console process group that shares the console associated with the calling process.
dwCtrlEvent
- The type of signal to be generated.
dwProcessGroupId
- The identifier of the process group to receive the signal
true
if successful - if false
then use GetLastError()
to get extended error information
int GetConsoleCP()
boolean SetConsoleCP(int wCodePageID)
wCodePageID
- The identifier of the code page to be set
true
if successful - if false
then use GetLastError()
to get extended error information
int GetConsoleOutputCP()
boolean SetConsoleOutputCP(int wCodePageID)
wCodePageID
- The output code page used by the console associated with the calling process.
true
if successful - if false
then use GetLastError()
to get extended error information
hConsoleInput
- A handle to the console input buffer. The handle must have the GENERIC_READ access right
lpcNumberOfEvents
- A pointer to a variable that receives the number of unread input records in the console's input buffer
true
if successful - if false
then use GetLastError()
to get extended error information
lpNumberOfMouseButtons
- A pointer to a variable that receives the number of mouse buttons
true
if successful - if false
then use GetLastError()
to get extended error information
nStdHandle
- The standard device identifier
nStdHandle
- The standard device identifier
hHandle
- The handle for the standard device
true
if successful - if false
then use GetLastError()
to get extended error information
Retrieves the display mode of the current console
lpModeFlags
- The display mode of the console
true
if successful - if false
then use GetLastError()
to get extended error information
hConsoleHandle
- A handle to the console input buffer or the console screen buffer. The handle must have the GENERIC_READ access right
lpMode
- A pointer to a variable that receives the current mode of the specified buffer
true
if successful - if false
then use GetLastError()
to get extended error information
hConsoleHandle
- A handle to the console input buffer or a console screen buffer. The handle must have the GENERIC_READ access right
dwMode
- The input or output mode mask to be set
true
if successful - if false
then use GetLastError()
to get extended error information
int GetConsoleTitle(char[] lpConsoleTitle, int nSize)
lpConsoleTitle
- A pointer to a buffer that receives a null-terminated string containing the title. If the buffer is too small to store the title, the function stores as many characters of the title as will fit in the buffer, ending with a null terminator. Note: use Native.toString(char[])
to convert it to a String
value
nSize
- The size of the buffer pointed to by the lpConsoleTitle parameter, in characters.
GetLastError
returns the error code.
int GetConsoleOriginalTitle(char[] lpConsoleTitle, int nSize)
lpConsoleTitle
- A pointer to a buffer that receives a null-terminated string containing the original title. Note: use Native.toString(char[])
to convert it to a String
value
nSize
- The size of the lpConsoleTitle buffer, in characters
GetLastError
returns ERROR_SUCCESS
. If the function fails, the return value is zero and GetLastError
returns the error code.
lpConsoleTitle
- The string to be displayed in the title bar of the console window. The total size must be less than MAX_CONSOLE_TITLE_LENGTH
.
true
if successful - if false
then use GetLastError()
to get extended error information
Retrieves information about the specified console screen buffer.
hConsoleOutput
- A handle to the console screen buffer.
lpConsoleScreenBufferInfo
- A pointer to a CONSOLE_SCREEN_BUFFER_INFO structure that receives the console screen buffer information.
true
if successful - if false
then use GetLastError()
to get extended error information
Reads data from a console input buffer and removes it from the buffer.
hConsoleInput
- A handle to the console input buffer.
lpBuffer
- A pointer to an array of INPUT_RECORD structures that receives the input buffer data.
nLength
- The size of the array pointed to by the lpBuffer parameter, in array elements.
lpNumberOfEventsRead
- A pointer to a variable that receives the number of input records read.
true
if successful - if false
then use GetLastError()
to get extended error information
Writes a character string to a console screen buffer beginning at the current cursor location.
hConsoleOutput
- A handle to the console screen buffer.
lpBuffer
- A pointer to a buffer that contains characters to be written to the console screen buffer.
nNumberOfCharsToWrite
- The number of characters to be written.
lpNumberOfCharsWritten
- A pointer to a variable that receives the number of characters actually written.
lpReserved
- Reserved; must be NULL.
true
if successful - if false
then use GetLastError()
to get extended error information
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4