网站首页  词典首页

请输入您要查询的函数:

 

术语 privateextracticons
释义 PrivateExtractIcons
语法:
UINT PrivateExtractIcons( LPCTSTR lpszFile,
int nIconIndex,
int cxIcon,
int cyIcon,
HICON *phicon,
UINT *piconid,
UINT nIcons,
UINT flags
);
PrivateExtractIcons功能
创建一个句柄数组是从一个指定的文件中提取图标。
参数
lpszFile
[in]指向一个空结束的字符串,指定路径和文件从它的名称的图标(s)是在被提取。
nIconIndex
[in]指定零为基础的第一个图标索引提取。例如,如果该值为0,函数提取指定文件中的第一个图标。
cxIcon
要[in]Level图标大小。见讲话。
cyIcon
要[in]垂直图标大小。见讲话。
phicon
[out]指向的图标返回的数组处理。
piconid
[out]指向一个最适合的图标当前显示设备产生资源标识符。返回的标识符是0xFFFFFFFF标识符如果没有这种格式。返回的标识符是0,如果该标识符不能以其他方式获得。
nIcons
[in]指定数目的图标从文件中提取。此参数时才有效提取。exe和。dll文件。
旗帜
[in]指定标志控制此功能。这些标志的*标志的LoadImage函数使用LR_。
返回值
如果phicon参数为NULL,这函数执行成功,则返回值是图标文件号。如果函数失败则返回值为0。
如果phicon参数不是NULL和函数调用成功,则返回值是多少提取的图标。否则则返回值是0xFFFFFFFF如果该文件未找到。
备注
从可执行(。exe这个函数中提取),DLL文件(。dll文件),图标(。伊科),光标(。当前),动画光标(。提肛),和位图(。bmp)文件。从Microsoft Windows 3.X中的16位可执行文件提取物(。exe或。dll文件)也支持。
在cxIcon和cyIcon参数指定图标的大小来提取。两种规格,可通过把提取的参数LOWORD第一的规模和在HIWORD第二的大小。例如,MAKELONG(24,48),同时为cxIcon和cyIcon参数都将提取24和48的大小的图标。
您必须摧毁PrivateExtractIcons提取DestroyIcon函数调用所有图标。
虽然您可以通过使用LoadLibrary和GetProcAddress的Windows版本相结合,在Windows XP之前,这个函数,该函数是无法访问使用标准的包含文件和库之间的联系。在Windows XP服务包1(SP1)和Windows Server 2003的这个功能现在是记载和加以利用,包括使用适当的文件和库之间的联系。但是,此函数是过时不一般的使用。我们建议您不要使用新的程序,因为这可能会更改或在Windows的后续版本中不可用。
功能信息
最低DLL版本 user32.dll
HeaderDeclared的Winuser.h
import libraryuser32.lib
2000年最低经营systemsWindows
UnicodeImplemented为ANSI和Unicode版本。
参见
图标概述,DestroyIcon,ExtractIcon,ExtractIconEx
==英文原文==PrivateExtractIcons Function
Creates an array of handles to icons that are extracted from a specified file.
Syntax
UINT PrivateExtractIcons( LPCTSTR lpszFile,
int nIconIndex,
int cxIcon,
int cyIcon,
HICON *phicon,
UINT *piconid,
UINT nIcons,
UINT flags
);
Parameters
lpszFile
[in] Pointer to a null-terminated string that specifies the path and name of the file from which the icon(s) are to be extracted.
nIconIndex
[in] Specifies the zero-based index of the first icon to extract. For example, if this value is zero, the function extracts the first icon in the specified file.
cxIcon
[in] Horizontal icon size wanted. See remarks.
cyIcon
[in] Vertical icon size wanted. See remarks.
phicon
[out] Pointer to the returned array of icon handles.
piconid
[out] Pointer to a returned resource identifier for the icon that best fits the current display device. The returned identifier is 0xFFFFFFFF if the identifier is not available for this format. The returned identifier is 0 if the identifier cannot otherwise be obtained.
nIcons
[in] Specifies the number of icons to extract from the file. This parameter is only valid when extracting from .exe and .dll files.
flags
[in] Specifies flags that control this function. These flags are the LR_* flags used by the LoadImage function.
Return Value
If the phicon parameter is NULL and this function succeeds, then the return value is the number of icons in the file. If the function fails then the return value is 0.
If the phicon parameter is not NULL and the function succeeds, then the return value is the number of icons extracted. Otherwise, the return value is 0xFFFFFFFF if the file is not found.
Remarks
This function extracts from executable (.exe), DLL (.dll), icon (.ico), cursor (.cur), animated cursor (.ani), and bitmap (.bmp) files. Extractions from Microsoft Windows 3.x 16-bit executables (.exe or .dll) are also supported.
The cxIcon and cyIcon parameters specify the size of the icons to to extract. Two sizes can be extracted by putting the first size in the LOWORD of the parameter and the second size in the HIWORD. For example, MAKELONG(24, 48) for both the cxIcon and cyIcon parameters would extract both 24 and 48 size icons.
You must destroy all icons extracted by PrivateExtractIcons by calling the DestroyIcon function.
Although you can access this function by using LoadLibrary and GetProcAddress combined in Windows versions prior to Windows XP, the function was not accessible using the standard Include file and library linkage. In Windows XP Service Pack 1 (SP1) and Windows Server 2003 this function is now documented and made accessible using the appropriate include file and library linkage. However, this function is deprecated not intended for general use. It is recommended that you do not use it in new programs because it might be altered or unavailable in subsequent versions of Windows.
Function Information
Minimum DLL Versionuser32.dll
HeaderDeclared in winuser.h
Import libraryuser32.lib
Minimum operating systemsWindows 2000
UnicodeImplemented as ANSI and Unicode versions.
See Also
Icons Overview , DestroyIcon , ExtractIcon , ExtractIconEx
==原始网址==http://msdn.microsoft.com/en-us/library/ms648075(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:17:39