 |
ReadConsole ..msdn Add comment W32 Constants Translate this page |
 |
 |
|
The ReadConsole function reads character input from the console input buffer and removes it from the buffer. |
 |
 |
| Code examples: |
 |
|
|
 |
 |
| Declaration: |
 |
 |
BOOL ReadConsole(
HANDLE hConsoleInput,
LPVOID lpBuffer,
DWORD nNumberOfCharsToRead,
LPDWORD lpNumberOfCharsRead,
LPVOID lpReserved
);
|
 |
 |
 |
| FoxPro declaration: |
 |
 |
DECLARE INTEGER ReadConsole IN kernel32;
INTEGER hConsoleInput,;
STRING @ lpBuffer,;
INTEGER nNumberOfCharsToRead,;
INTEGER @ lpNumberOfCharsRead,;
INTEGER lpReserved
|
 |
 |
 |
| Parameters: |
 |
hConsoleInput
[in] Handle to the console input buffer.
lpBuffer
[out] Pointer to a buffer that receives the data read from the console input buffer.
nNumberOfCharsToRead
[in] Number of TCHARs to read.
lpNumberOfCharsRead
[out] Pointer to a variable that receives the number of TCHARs actually read.
lpReserved
[in] Reserved; must be NULL. |
 |
 |
| Return value: |
 |
| If the function succeeds, the return value is nonzero. |
 |
 |
| My comment: |
 |
The total size of the buffer required will be less than 64K.
Use GetStdHandle with STD_INPUT_HANDLE to obtain the handle to the console input buffer.
See also: WriteConsole. |
 |
 |
| Translate this page: |
 |
|
 |
 |
| • |
 |
| Created: | 2004-11-10 09:25:54 | | Modified: | 2004-11-10 09:29:20 | Visited in last 7 days: 14 |