Solved

for bin_huwairib

Posted on 1998-06-07
6
180 Views
Last Modified: 2010-05-03
Some time ago you recommended a means of extracting a file's icon with SHGetFileInfo.  Can you recommend a means of extracting an file's icon simply based on it's file extension.  Since I am creating an FTP client program and using a treeview and listview control, I would like to represent the remote files with their corresponding images and cannot use SHGetFileInfo for this task.  Any advice would be appreciated.  Thanks, John
0
Comment
Question by:hozempa
  • 2
  • 2
  • 2
6 Comments
 
LVL 4

Expert Comment

by:zsi
Comment Utility
You can maintain an image list that has icons for the files that you want to support.  However, there are a lot of file extension combinations out there.  Also, you will not be able to show the individual icons for executable programs, normally the program's icon.
0
 
LVL 5

Expert Comment

by:bin_huwairib
Comment Utility
hozempa,

I'm sorry because of my late response.

zsi is correct, it is better to create an image list for the supported extensions and it is usually a binary file icon and a text file icon. And regarding SHGetFileInfo it won't work because it's require the file to be exist in the client machine to be able to extract the icon. And in your case you just have the name of the file so you need to download the whole file first in order to use this function which is not practical.

Anyway if you need any further information, check the article Q175179 at http://support.microsoft.com


Best regards
Bin Huwairib
0
 
LVL 1

Author Comment

by:hozempa
Comment Utility
Bin Huwairib, thanks for the information.  I didn't think there was a way to do it aside from transferring the files onto the local system.   Still, I appreciate the response.  If you would still like the points, please send any answer to this question.
Thanks, hozempa
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 5

Expert Comment

by:bin_huwairib
Comment Utility
hozempa,

I will be glad if you give the points to szi because he had respond before me, beside my comment was not so far from his that's why he deserve it.

zsi, please lock the question to get the points.


Best regards
Bin Huwairib
0
 
LVL 1

Author Comment

by:hozempa
Comment Utility
That's fine with me, if it's agreeable with you.  Zsi, please post any response and I'll award you the points.
0
 
LVL 4

Accepted Solution

by:
zsi earned 50 total points
Comment Utility
Of course, this question *was* directed to Bin.  I was just adding a comment.  Didn't mean to snag the points from ya, Bin. :)
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now