How to retrieve the file icons and file previews used by windows explorer?
- by user193655
I am developing a Delphi documents management application, so somehow I am giving the user some functionality similar to windows explorer.
Currently I am using imagelists where I manually maintain the icons (like one for pdf, one for xls, ...) and when I need to display an icon for a filetype that I don't explicitly support I have a generic icon. Is there a way to retrieve the icon used by windows, like
MyTImage := GiveMeDefaultIconForExtension('pdf');
In Vista and Seven this should be an icon with multiple resolutions I think.
Moreover I would like to know if there is a way to get the preview used by windows explorer. For example windows explorer creates a small thumbnail for a pdf document for example, and displays it when the user chooses to view "big icons". Is there a way to retrieve that preview?
MyTImage := GiveMePreviewForFile('C:\Test\File.pdf');