术语 | loadmenu |
释义 | LoadMenu 语法: HMENU LoadMenu( HINSTANCE hInstance, LPCTSTR lpMenuName ); LoadMenu函数 该LoadMenu函数加载的可执行(。exe指定的菜单资源)文件与一个应用程序实例。 参数 hInstance [in]句柄模块包含菜单资源加载。 lpMenuName [in]指向一个空结束的字符串,其中包含菜单资源的名称。另外,此参数可以包括在低位字资源标识符和高位字为零。要创建此值,使用MAKEINTRESOURCE宏。 返回值 如果函数成功,返回值是一个句柄菜单资源。 如果函数失败,返回值为NULL。为了获得更多错误信息,调用GetLastError。 备注 DestroyMenu函数的使用,应用程序关闭之前,摧毁菜单和自由内存加载的菜单占领。 在Windows 95/98/Me:LoadMenuW是支持微软层对于Unicode。要使用此,您必须将某些文件到您的应用,概述了对Unicode的Microsoft层在Windows 95/98/Me系统。 例如 有关示例,请参见显示快捷菜单 功能信息 最低DLL版本 user32.dll 在Winuser.h中HeaderDeclared,头文件:winuser.h import libraryUser32.lib 最低操作系统Windows 95,Windows NT 3.1 UnicodeImplemented为ANSI和Unicode版本。 参见 菜单,LoadMenuIndirect,MAKEINTRESOURCE ==英文原文==LoadMenu Function The LoadMenu function loads the specified menu resource from the executable (.exe) file associated with an application instance. Syntax HMENU LoadMenu( HINSTANCE hInstance, LPCTSTR lpMenuName ); Parameters hInstance [in] Handle to the module containing the menu resource to be loaded. lpMenuName [in] Pointer to a null-terminated string that contains the name of the menu resource. Alternatively, this parameter can consist of the resource identifier in the low-order word and zero in the high-order word. To create this value, use the MAKEINTRESOURCE macro. Return Value If the function succeeds, the return value is a handle to the menu resource. If the function fails, the return value is NULL. To get extended error information, call GetLastError . Remarks The DestroyMenu function is used, before an application closes, to destroy the menu and free memory that the loaded menu occupied. Windows 95/98/Me: LoadMenuW is supported by the Microsoft Layer for Unicode. To use this, you must add certain files to your application, as outlined in Microsoft Layer for Unicode on Windows 95/98/Me Systems . Example For an example, see Displaying a Shortcut Menu Function Information Minimum DLL Versionuser32.dll HeaderDeclared in Winuser.h, include Windows.h Import libraryUser32.lib Minimum operating systemsWindows 95, Windows NT 3.1 UnicodeImplemented as ANSI and Unicode versions. See Also Menus , LoadMenuIndirect , MAKEINTRESOURCE ==原始网址==http://msdn.microsoft.com/en-us/library/ms647990(VS.85).aspx\n |
随便看 |
|
windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。