网站首页  词典首页

请输入您要查询的函数:

 

术语 peekconsoleinput
释义 PeekConsoleInput
语法:
C++
BOOL WINAPI PeekConsoleInput(
__in HANDLE hConsoleInput,
__out PINPUT_RECORD lpBuffer,
__in DWORD nLength,
__out LPDWORD lpNumberOfEventsRead
);
PeekConsoleInput功能
读取指定的控制台下,清除缓冲区的输入缓冲区的数据。
参数
hConsoleInput [in]
句柄到控制台输入缓冲区。句柄必须有GENERIC_READ访问的权利。有关更多信息,参见控制台缓冲区安全和访问权限。
lpBuffer [out]
一个一个INPUT_RECORD结构的数组,它接收输入缓冲区数据指针。在将小于64K的要求阵列的总规模。
nLength [in]
数组的大小指向的lpBuffer参数,在数组元素。
lpNumberOfEventsRead [out]
一个变量,它接收的输入读取记录数的指针。
返回值
如果函数成功,返回值为非零。
如果函数失败,返回值是零。为了获得更多错误信息,调用GetLastError。
备注
如果请求的记录数超过了缓冲区中的记录数目,可用数字读取。如果没有数据可用,函数立即返回。
此函数使用任何Unicode字符或8位字符从控制台的当前代码页。控制台的代码页默认最初系统的OEM代码页。要更改控制台的代码页,使用SetConsoleCP或SetConsoleOutputCP功能,或使用chcp处长或节能模式选择=命令。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWincon.h(头文件:winuser.h)
LibraryKernel32.lib
DLLKernel32.dll
Unicode和ANSI namesPeekConsoleInputW(Unicode)和PeekConsoleInputA(ANSI)的
参见
控制台函数
ReadConsoleInput
SetConsoleCP
SetConsoleOutputCP
WriteConsoleInput
INPUT_RECORD
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年8月27日
==英文原文==PeekConsoleInput Function
Reads data from the specified console input buffer without removing it from the buffer.
Syntax
C++
BOOL WINAPI PeekConsoleInput(
__in HANDLE hConsoleInput,
__out PINPUT_RECORD lpBuffer,
__in DWORD nLength,
__out LPDWORD lpNumberOfEventsRead
);
Parameters
hConsoleInput [in]
A handle to the console input buffer. The handle must have the GENERIC_READ access right. For more information, see Console Buffer Security and Access Rights .
lpBuffer [out]
A pointer to an array of INPUT_RECORD structures that receives the input buffer data. The total size of the array required will be less than 64K.
nLength [in]
The size of the array pointed to by the lpBuffer parameter, in array elements.
lpNumberOfEventsRead [out]
A pointer to a variable that receives the number of input records read.
Return Value
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero. To get extended error information, call GetLastError .
Remarks
If the number of records requested exceeds the number of records available in the buffer, the number available is read. If no data is available, the function returns immediately.
This function uses either Unicode characters or 8-bit characters from the console's current code page. The console's code page defaults initially to the system's OEM code page. To change the console's code page, use the SetConsoleCP or SetConsoleOutputCP functions, or use the chcp or mode con cp select= commands.
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWincon.h (include Windows.h)
LibraryKernel32.lib
DLLKernel32.dll
Unicode and ANSI namesPeekConsoleInputW (Unicode) and PeekConsoleInputA (ANSI)
See Also
Console Functions
ReadConsoleInput
SetConsoleCP
SetConsoleOutputCP
WriteConsoleInput
INPUT_RECORD
Send comments about this topic to Microsoft
Build date: 8/27/2009
==原始网址==http://msdn.microsoft.com/en-us/library/ms684344(VS.85).aspx\n
随便看

 

windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。

 

Copyright © 2004-2023 Winrtm.com All Rights Reserved
京ICP备2021023879号-40 更新时间:2024/10/6 13:20:45