The main reason for making this file explorer is so I can debug all problems in it. Like Microsofts File Explorer a common bug keeps coming up in directorys with a large amount of files, says something like "Cannot read from blah.." and explorer crashes. I searched the internet for a similar program like that, that I could use as a replacement and I could not find one. So, to make it possible to view those directorys, I will just make my own version of mircrosofts file explorer, that essentialy does the same thing.
Exploeres dont really use there own set of icons, for the file types atleast. The associated file type icons are global, the program sets it when its installed. The only ones that are default are hte default system icons. So really its not me how needs to make my own, except maybe for the back, refresh, forward, etc buttons on the toolbar.
I dont think there is any icon thing built into .NET atleast not one that gets the icon for the associated file type. Ive searched google through and through and finally came up with one result for .NET that does what im trying, it was the only useful result I found after looking through hundreds of web pages. It does basicaly what you were saying to do Rory. I cant get it to work though.
http://www.codeguru.com/vb/gen/vb_mi...cle.php/c5597/
That is what I found, it doesnt work because I keep getting on this line:
myIcon = System.Drawing.Icon.FromHandle(shinfo.hIcon)
That it gives me an error saying its not valid, in the variable view hIcon is equal to 0 so theres a problem somewhere, I worked with this for 2 hours so far changing it around, and I cannot figure out what is wrong. I dont really even understand how the code is working or running either... its hard to follow with the shinfo because its not plainly defined as other variables are.
EDIT
Actually now trying it exactly as its done on the site, it works, it was the way I modified it in my for each loop that was causing the problem. For some reason it doesnt want to work like im thinking it should. I will try a few things diffrent and do tests on the working and not working one and try to find out whats wrong.