private static IntPtr GetIcon(string path,FileAttributeFlags attrFlags, SHGetFileInfoFlags dwFlag) { SHFILEINFO fi = new SHFILEINFO(); int iTotal = (int)SHGetFileInfo(path, attrFlags, ref fi, 0, dwFlag); return fi.hIcon; }
public static extern IntPtr SHGetFileInfo(string path, uint fileAttributes, ref SHFILEINFO psfi, int cbFileInfo, SHGetFileInfoFlags uFlags);
public static extern IntPtr SHGetFileInfo(string path, uint fileAttributes, ref SHFILEINFO psfi, int cbFileInfo, SHGetFileInfoFlags uFlags);
public static extern IntPtr SHGetFileInfo( string pszPath, FileAttributeFlags dwFileAttributes, ref SHFILEINFO psfi, uint cbSizeFileInfo, SHGetFileInfoFlags uFlags);
public static extern IntPtr SHGetFileInfo(string path, uint attributes, ref ShellFileSystemInfo info, int fileInfoSize, SHGetFileInfoFlags flags);
public static extern IntPtr SHGetFileInfo(string path, uint attributes, ref ShellFileSystemInfo info, int fileInfoSize, SHGetFileInfoFlags flags);
private static extern IntPtr SHGetFileInfo(string pszPath, uint dwFileAttributes, out SHFILEINFO psfi, uint cbFileInfo, SHGetFileInfoFlags uFlags);
public static extern IntPtr SHGetFileInfo(string pszPath, uint dwFileAttributes, ref SHFileInfo psfi, uint cbSizeFileInfo, SHGetFileInfoFlags uFlags);
private static extern Int32 SHGetFileInfo(String path, Int32 fileAttributes, out SHFileInfo fileInfo, UInt32 fileInfoSize, SHGetFileInfoFlags flags);