网站首页  词典首页

请输入您要查询的函数:

 

术语 setconsolecp
释义 SetConsoleCP
语法:
C++
BOOL WINAPI SetConsoleCP(
__in UINT wCodePageID
);
SetConsoleCP功能
设置输入代码页控制台调用进程的相关使用。阿控制台使用代码页的投入转化为相应的字符值键盘输入。
参数
wCodePageID [in]
该标识符代码页设置。代码页的本地计算机上可用的标识符存储在注册表中以下项下。
HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Nls\\CodePage
如需标识符列表,请参阅代码页标识符。
返回值
如果函数成功,返回值为非零。
如果函数失败,返回值是零。为了获得更多错误信息,调用GetLastError。
备注
代码页256字符代码映射到单个字符。不同的代码页包括不同的特殊字符,通常用于语言或语言群体定制。要检索更多信息的代码页,包括它的名字,看到GetCPInfoEx功能。
要确定一个控制台的电流输入代码页,使用GetConsoleCP功能。设置和检索一个控制台的输出代码页,使用SetConsoleOutputCP和GetConsoleOutputCP功能。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWincon.h(头文件:winuser.h)
LibraryKernel32.lib
DLLKernel32.dll
参见
控制台代码页
控制台函数
GetConsoleCP
GetConsoleOutputCP
SetConsoleOutputCP
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年8月27日
==英文原文==SetConsoleCP Function
Sets the input code page used by the console associated with the calling process. A console uses its input code page to translate keyboard input into the corresponding character value.
Syntax
C++
BOOL WINAPI SetConsoleCP(
__in UINT wCodePageID
);
Parameters
wCodePageID [in]
The identifier of the code page to be set. The identifiers of the code pages available on the local computer are stored in the registry under the following key.
HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Nls\\CodePage
For a list of identifiers, see Code Page Identifiers .
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
A code page maps 256 character codes to individual characters. Different code pages include different special characters, typically customized for a language or a group of languages. To retrieve more information about a code page, including it's name, see the GetCPInfoEx function.
To determine a console's current input code page, use the GetConsoleCP function. To set and retrieve a console's output code page, use the SetConsoleOutputCP and GetConsoleOutputCP functions.
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWincon.h (include Windows.h)
LibraryKernel32.lib
DLLKernel32.dll
See Also
Console Code Pages
Console Functions
GetConsoleCP
GetConsoleOutputCP
SetConsoleOutputCP
Send comments about this topic to Microsoft
Build date: 8/27/2009
==原始网址==http://msdn.microsoft.com/en-us/library/ms686013(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:16:27