哪位高手能告诉小弟我如何在Image或者picture里头显示系统常量图标

谁能告诉我怎么在Image或者picture里头显示系统常量图标!我想在image里头显示 系统 常数表示的那些图标(或

谁能告诉我怎么在Image或者picture里头显示系统常量图标!
我想在image里头显示 系统 常数表示的那些图标(或者图片)

比如 vbinformation 这样的 , 不知道有没有直接加载这些图标的函数

这样用肯定是不对的 image1.picture = loadpicture(vbinformation)

有什么好的办法么? 难道必须一个一个的去截图做成图片文件吗?


[解决办法]
哦 你把 显示桌面的图标 拖到记事本里看看系统调用了那个图标 ,然后你依次试试其它的序号。
然后你就从系统的一个dll中按序号调用图标即可。

[解决办法]
这些图标在user32.dll里面
LoadIcon
The LoadIcon function loads the specified icon resource from the executable (.EXE) file associated with an application instance. This function has been superseded by the LoadImage function

HICON LoadIcon(
HINSTANCE hInstance, // handle to application instance
LPCTSTR lpIconName // icon-name string or icon resource 
// identifier
);
 
Parameters
hInstance 
Handle to an instance of the module whose executable file contains the icon to be loaded. This parameter must be NULL when a standard icon is being loaded. 
lpIconName 
Pointer to a null-terminated string that contains the name of the icon resource to be loaded. Alternatively, this parameter can contain the resource identifier in the low-order word and zero in the high-order word. Use the MAKEINTRESOURCE macro to create this value. 
To use one of the predefined icons, set the hInstance parameter to NULL and the lpIconName parameter to one of the following values: Value Description 
IDI_APPLICATION Default application icon. 
IDI_ASTERISK Same as IDI_INFORMATION. 
IDI_ERROR Hand-shaped icon. 
IDI_EXCLAMATION Same as IDI_WARNING. 
IDI_HAND Same as IDI_ERROR.
IDI_INFORMATION Asterisk icon. 
IDI_QUESTION Question mark icon. 
IDI_WARNING Exclamation point icon. 
IDI_WINLOGO Windows logo icon. 



Return Values
If the function succeeds, the return value is a handle to the newly loaded icon.

If the function fails, the return value is NULL. To get extended error information, callGetLastError. 

Remarks
LoadIcon loads the icon resource only if it has not been loaded; otherwise, it retrieves a handle to the existing resource. The function searches the icon resource for the icon most appropriate for the current display. The icon resource can be a color or monochrome bitmap. 

LoadIcon can only load an icon whose size conforms to the SM_CXICON and SM_CYICON system metric values. Use the LoadImage function to load icons of other sizes.

Windows CE: Predefined icons (IDI_*) are not supported. 

In Windows CE 1.0, the icon must be a two bit per pixel (.ic2) icon or a monochrome icon. 

See Also
Icons Overview, Icon Functions, CreateIcon, LoadImage, MAKEINTRESOURCE 


[解决办法]
ExtractIcon
The ExtractIcon function retrieves a handle to an icon from the specified executable file, dynamic-link library (DLL), or icon file. 

To retrieve an array of handles to large or small icons, use the ExtractIconEx function. 

HICON ExtractIcon(
HINSTANCE hInst, // instance handle
LPCTSTR lpszExeFileName, // filename of file with icon
UINT nIconIndex // index of icon to extract
);
 
Parameters
hInst 
Handle to the instance of the application calling the function. 
lpszExeFileName 
Pointer to a null-terminated string specifying the name of an executable file, DLL, or icon file. 
nIconIndex 
Specifies the zero-based index of the icon to retrieve. For example, if this value is 0, the function returns a handle to the first icon in the specified file. 


If this value is –1, the function returns the total number of icons in the specified file. If the file is an executable file or DLL, the return value is the number of RT_GROUP_ICON resources. If the file is an .ICO file, the return value is 1. 

Windows 95, Windows NT 4.0, and later: If this value is a negative number not equal to -1, the function returns a handle to the icon in the specified file whose resource identifier is equal to the absolute value of nIconIndex. For example, use -3 to extract the icon whose resource identifier is 3. To extract the icon whose resource identifier is 1, use the ExtractIconEx function. 

Return Values
The return value is a handle to an icon. If the file specified was not an executable file, DLL, or icon file, the return is 1. If no icons were found in the file, the return value is NULL. 

Remarks
You must destroy the icon handle returned by ExtractIcon by calling the DestroyIcon function. 

QuickInfo
Windows NT: Requires version 3.1 or later.
Windows: Requires Windows 95 or later.
Windows CE: Unsupported.
Header: Declared in shellapi.h.
Import Library: Use shell32.lib.
Unicode: Implemented as Unicode and ANSI versions on Windows NT.

See Also
Icons Overview, Icon Functions, DestroyIcon, ExtractIconEx 

 

[解决办法]
楼主想调用系统的是吧 干脆自己做一个套吧 还挺有个性