ShellBrowser Delphi Components Documentation
ContentsIndexHome
PreviousUpNext
ShellBrowser.TJamSystemImageList.GetSpecialFolderIcon

Returns the icon number for a given special folder.

Syntax
Pascal
function GetSpecialFolderIcon(folder: TJamShellFolder): Integer;
Parameters 
Description 
folder: TJamShellFolder 
The special folder of interest.  

The requested icon number.

This method returns the icon number of a TJamShellFolder, like the network or the control panel. You can use this index for example with the Draw method, that this component inherits from its parent component TImageList, or with the ImageIndex property of Delphi's TTreeNode and TListItem objects.  

The following code will draw the icon for the nethood on the canvas of the form:  

 

With TJamSystemImageList do
  Draw(Canvas, 10, 10, GetSpecialFolderIcon(SF_NETWORK));