Getting the default icon from a filepath even if the file isn't available

710 views Asked by At

I'm trying to get the associated icon for a file so I can display it in a ListView in my VB.Net code.

However, I can't use the ExtractAssociatedIcon function that all the Googling I've done points me to, because this is for a cataloguing function and the original file is not accessible, so all I have is the file path as a string (from which I can extract just the extension if necessary).

Is there a way I can get the default icon for a particular file extension, even if the file's unavailable?

Thanks

0

There are 0 answers