Jump to content
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble

MSFN is made available via donations, subscriptions and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, register and become a site sponsor/subscriber and ads will be disabled automatically. 

Sign in to follow this  
Zoinkity

Folder Icons

Recommended Posts

This may be useful for those people who use stuff cross-platform, like USB stick drives. Folder icons have stuck around from the win9x era all the way to Vista, but it seems no two versions expect the same thing. Here's the sure-fire way to ensure that your icon will be visible on every version.

+_+

First, set both the "system" and "read-only" flags for the folder you're changing the icon from. To set the system flag you'll need to open a command window and type in something like this:

attrib "FOLDERNAME" +s

The system flag is required by win9x, but read-only is required by NT versions.

Next, create a file inside the folder called "desktop.ini", traditionally set as system and hidden although this is questionably required. Here's a sample of what one should look like:

[.ShellClassInfo]
IconFile=notepad++.exe
IconIndex=0
IconResource=notepad++.exe,0

"IconResource" is Vista's means of finding icons and doesn't work XP and below. They expect the "IconFile" + "IconIndex" lines. If there is only one icon in the file, you can use just the IconFile line. In both of these examples it is included anyway.

You can also use relative paths. Remember the path is from the current folder, so if there was an icon PopEye.ico in the directory above, you would type this:

[.ShellClassInfo]
IconFile=..\PopEye.ico
IconIndex=0
IconResource=..\PopEye.ico,0

=_=

Like any desktop.ini, you can also tack in other features such as InfoTips, set shell extensions, and other such nonsense, with varying degrees of sucess depending on what version you're using.

Share this post


Link to post
Share on other sites

Thanks for these informations.

However bear in mind that folders set as system folder won't be defragmented (at least on w98 ).

So if you do that, temporarily reset the folder attribute to normal before defragmenting.

Also doesn't read-only means that it's read-only? I mean that you can write in it?

Edited by Fredledingue

Share this post


Link to post
Share on other sites

@Fredledingue:

A folder being set as read-only has no bearing to Windows (as far as write/delete-abiltiy goes). It probably means, under DOS, a rmdir won't work on that folder, but I'm not positive.

In the case of Flash Drives, being able to defragment or not doesn't matter. There are likely third party defragmenters that don't care about the folder's attributes for defragmenting purposes.

@Zoinkitty:

Are you positive read-only needs to be set for the icon to work? When you say NT, do you mean literally Windows NT, or the NT line (2000, XP, Vista) in general? As far as I know I haven't been setting my folders as read-only (intentionally) on my Flash Drive, and have never seen the folder icons not work, but I've never used it on a Windows NT machine (only 98SE, ME, XP and Vista).

Queue

Share this post


Link to post
Share on other sites
...

The system flag is required by win9x, but read-only is required by NT versions.

...

...

@Zoinkitty:

...When you say NT, do you mean literally Windows NT, or the NT line (2000, XP, Vista) in general?...

Zoinkity posted "NT versions" plural, so he means the NT line in general.

Share this post


Link to post
Share on other sites

Or you can try something like this:

krasotaem6.png

Edited by marxo

Share this post


Link to post
Share on other sites
The system flag is required by win9x, but read-only is required by NT versions.
:blink: I wasn't aware of this! Thanks a lot, Zoinkity! You rock! :thumbup
[.ShellClassInfo]
IconFile=..\PopEye.ico
IconIndex=0

I wish to add that Win XP (and all NT family OSes) requires IconIndex even when the IconFile is a single-icon .ico file, whereas Win 9X/ME doesn't mind if it's not there, in this case. If the icon is in a file that contains multiple icons, of course, both families do require the IconIndex entry, so as to be able to find the intended icon.

Edited by dencorso

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×