Board index » delphi » How to get icon associated with a file?

How to get icon associated with a file?

I was wondering if anyone knows how to retrieve the icon for a file in
Windows 95.  I'm trying to create a listview in a contact manager that will
let the user drag and drop files to be associated with the particular
contact.  I've got everything (I think) working except I don't have any
nice little icons... so if anyone has any experience with this, I'd
appreciate it.

Thanks in advance.

--
Bryan Brandt - <umbra...@cc.umanitoba.ca>

 

Re:How to get icon associated with a file?


NumIcons := LongInt(ExtractIcon( 0, FileName, -1 ) // Returns Number of
Icons in the file
hIcon := ExtractIcon( 0, Filename, iCount ); // Returns handle to icon in
position specified by iCount

Bryan Brandt <umbra...@cc.umanitoba.ca> wrote in article
<01bbc87a$3393a520$1f98b382@mandial>...

Quote
> I was wondering if anyone knows how to retrieve the icon for a file in
> Windows 95.  I'm trying to create a listview in a contact manager that
will
> let the user drag and drop files to be associated with the particular
> contact.  I've got everything (I think) working except I don't have any
> nice little icons... so if anyone has any experience with this, I'd
> appreciate it.

> Thanks in advance.

> --
> Bryan Brandt - <umbra...@cc.umanitoba.ca>

Other Threads