public static Icon GetIconForExtension(string extension, ShellIconSize size) { // repeat the process used for files, but instruct the API not to access the file size |= (ShellIconSize)SHGFI_USEFILEATTRIBUTES; return GetIconForFile(extension, size); }