C#.net获取文件类型的图标 [英] C# .net getting icon of a file type
本文介绍了C#.net获取文件类型的图标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
C#.net:如何获取特定文件的图标?例如,如何获取文件"Notepad.exe"的图标?
C# .net: How to get the icon of a specific file? for eg., How to get the icon of the file ''Notepad.exe''?
推荐答案
在Codeproject ^ ].
Check out an article of it on Codeproject here[^].
1.打开Visual Studio
2.按Ctrl + O
3.选择一个exe文件(在您的情况下为NotePad.exe)
4.展开图标"
5.右键单击特定图标,然后从菜单中选择导出..."
1. Open Visual Studio
2. Press Ctrl + O
3. Choose an exe file (In your case NotePad.exe)
4. Expand the "Icon"
5. Do right click on the specific icon and choose "Export..." from the menu
我几个月前写了一个小程序,它从exe文件中获取图标.
您可以检查我的代码或从我的博客中下载它.
http://perschluter.com/extract-associated-icon-from-exe -file-in-c-sharp/ [
I wrote a little program a couple of months ago that gets the icon from exe files.
You can check my code or download it from my blog.
http://perschluter.com/extract-associated-icon-from-exe-file-in-c-sharp/[^]
这篇关于C#.net获取文件类型的图标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文