../Msgboard/General customization/Custom Folders in My ComputerHome
bittemei - 27 Jan. 2003 - 10:08:

Custom Folders in My Computer

The goal of this hack is to create a custom folder(s) in My Computer, pointing to a directory on a local(or network) drive, have that folder visible in the Open/Save dialog boxes, browseable in the Explorer Tree-View, AND (optionally) integrate the whole thing into the Folder Options so you can easily turn this folder on/off (on a PER-USER basis)without editing the registry.

There are a few hacks out there that can add a folder to My Computer, but they all involve using shell32.dll, and calling explorer.exe to open the folder, which pops up a NEW explorer window every time, isn't browseable in the Explorer tree, and doesn't show up in Open/Save dialogs. I also wanted the folder(s) to behave according to the options you set under Folder Options(opening in a new window or the same window).

This has only been tested on WinXP Pro, YMMV, if you try it on another OS please post as to wether it worked or not.

The example reg entries create a system folder called 'Installers', pointing to D:\Installers\
In this example I used CLSID {25892e17-80f6-415f-9c65-7395632f0223} since it's supposed to be 'unused'. If you HAVE a CLSID key with this name in the registry already, pick another CLSID and replace every {25892e17-80f6-415f-9c65-7395632f0223} in both reg files with the new CLSID. What specific CLSID you use isn't important as long as you use the same CLSID for all the settings for each individual custom folder.

I've posted the reg files you need - merge them, then edit the values with Regedit AFTERWARDS. I had a TON of problems with this not working b/c a reg entry was the wrong type when I tried to create all the reg entries manually.

Step 1:
Creates a custom folder in My Computer.
Installers.reg

now go to [HKEY_CLASSES_ROOT\CLSID\{25892e17-80f6-415f-9c65-7395632f0223}] and edit the following values:
\(Default) - What name you want on the folder.
\InfoTip - The infotip for it...
\DefaultIcon\(Default) - full path to the icon you want on it.
\Instance\InitPropertyBag\Target - full path to the target folder.

That's it. - you should have a working folder.

Step 2 (Optional) - Adds a custom entry into the 'Folder Options' page to turn on/off the custom folder.
InstallersOption.reg

Merge this file, then change the following key/value:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\SFInstallersInMyComputer] - Rename the key to reflect the Specific Folder.
\Text - What you want the option line to read.

you should now have something that looks like this:
foldopt.gif


If you're setting up multiple custom folders, make sure to update the CLSID to a new unused one.

If you look at the reg keys in these areas, there's a TON of stuff that can be done in the future, too. Fun, hmm?

TO DO: Not much. I'm going to try and find a way to make a properties sheet for the folder that lets you edit the appropriate reg settings without going into regedit. If I can do it, people will be able to run a .reg file to install, and configure it all from the properties sheet. Idiot Proof. :D

UPDATE: Updated .reg files with new Attribute Values. They now produce fully functioning Custom Folders. Updated TO Do list. Updated the main text for improved 'readability'.

Mei
 
27 Jan. 2003 - 10:12 bittemei
Here are some links I found dealing with Shell Folder attributes, anybody who wants to look thru them, I'll be grateful, kinda burned out right now... PHEW.

http://www.vbaccelerator.com/home/VB/Type_Libraries/IShellFolder/IShellFolder_Type_Library_Source_Code_zip_ISHFoldr_odl.asp

http://www.clipcode.net/content/shell_guide/04_registry_settings.htm

Mei
 
27 Jan. 2003 - 10:27 WinT
Bittemei, love this man. Good find, good job. Will try on 98 and let you know how it works. :)
 
27 Jan. 2003 - 19:30 Explicit
Nice links mei. I'm always into that reading all kinds of stuff even if 51% doesn't make sense to me, as you might know.
 
27 Jan. 2003 - 20:24 Blackmage
Bittemei, what do you mean by in the open and save dialogs? If you are on XP you can add it to the sidebar on open/save dialogs easily with TweakUI for XP power toys. A little descrioption might help.
 
27 Jan. 2003 - 21:23 bittemei
BM:
What I mean, is in Windows XP, the 'Shared Documents' (aka "Documents Stored On This Computer") are shell folders that show up in My Computer, in Open/Save dialogs, and behave like folders in My Computer. See this shot if you need help understanding. opensave.gif.
See how it shows 'Documents' ; 'nobody's Documents' ;and Bill Gates's Documents' - those are all folders in My Computer. That's what I want.

I know I can set custom locations in the 'My Places' sidebar in Open/Save boxes, as you can see in the screenshot, I've been doing that - but you only get room for five there, and I have a lot more than five things I need to get to on a regular basis. Yeah, I know they make software to do that, too, but since I know it CAN be done without software, I want to know how.

Mei
 
28 Jan. 2003 - 03:25 Blackmage
I have yet to do this hack (I'm a little sick at the moment, plus some other things) but I would assume the folder would have been put in C:\Documents and Settings\All Users\Foldername, but this seems to not be the case, simply because it's mostly a per-user setting (Which is nice with XP Pro)... I was wondering about this because if we could at least get software to link to the folders, it must be possible some other way. Then again, this hack is 'pointless' to me because I disabled the shared documents tab. However, I have noticed that with the administrator account, if shared documents is enabled, you can see every users documents (as you should be able to)

Don't know if it helped, but...
 
28 Jan. 2003 - 18:20 bittemei
No Offense, but I think you're missing the point. This hack has nothing to do with the 'Shared Documents' folders, except as an EXAMPLE of what we're able to do with folders in XP. It also has nothing to do with anything in the 'Douments and Settings' folder.

The point, is to create custom folders in My computer pointing to REAL folders on a local drive.

As for WHY, well, I admit, it's more useful to me, with my 8 HDD's and over 300GB of stuff, than Joe Average with 1 or 2 HDD's and maybe 80GB - but it makes it easier to get to things, more intuitive, and when combined with NTFS mountpoints in XP, can make 'My Computer' look really nice and streamlined.

I'll post some screenshots of what I mean by 'Streamlined' and 'Intuitive' after I get home tonight.

Mei
 
28 Jan. 2003 - 23:23 Explicit
I'd like to be able to use this hack for when I'm using LiteStep, then when I click on My Computer in my popup, I can get to specific folders quicker and it saves time. Nothing to do with Shared Docs.
 
29 Jan. 2003 - 01:20 JohnnyFist
Explicit, why not just create shortcuts to those folders and put them in a folder somewhere. Then direct your popup to the folder with all the shortcuts.
 
29 Jan. 2003 - 02:41 bittemei
Ok, I said I'd post some screenshots of a 'Streamlined & Intutive' My Computer, so here ya go:

Before: Before.gif

After: After.gif

and a closeup shot of the icons, they're pretty cool :-) : AfterIcons.jpg

Hopefully this should give people an idea of what's possible with this. NOTE: All the drives are still there, just remapped to folder mountpoints inside the C: - if you don't feel like doing this(or don't have NTFS), you can just hide them in My Computer.

Update: I added them to the folder options list: AfterOptions.gif

Mei
 
29 Jan. 2003 - 02:52 Blackmage
sorry bettemei, but you did mention the open/save dialogs and shared documents. sorry for being an idiot and wasting your time.
 
29 Jan. 2003 - 03:17 bittemei
BM: Sorry if I came off a little harsh, didn't mean to, man. I deal with idiots all day at work, so sometimes I can get a little annoyed when people misunderstand me. Hope you feel better soon, and give this a try - you're one of the few other regulars here that I know has XP, so I'm waiting to see how it turns out for you.

Mei
 
29 Jan. 2003 - 03:58 Explicit
JohnnyFist - I could do that, but then there would still be two different windows to get to all the things I want in one, and wheres the challenge in creating a folder?
 
29 Jan. 2003 - 06:04 Blackmage
I'll delete that post when I get around to it, it was pretty stupid of me, I guess. I just kinda usually feel really stupid when I misunderstand things, don't worry too much about it. Also today was kinda shitty because nothing much happened at school andI'll try the hack tomorrow, I'm staying home regaurdless if I have strep throat or not, and I think 18+ hours will be enough time to get around to it, hehe.

Also, I understand about others being idiots at work (what I like to call school) my computer applications II class, save the last row in the back, is filled with idiots when it comes to computers. Soon I'm printing the shirt 'No, I will not fix your computer' :D
 
30 Jan. 2003 - 04:30 bittemei
The Delete button appears to not be working... It asks me if I'm sure, and then... no deletion happens.

Mei :D
 
30 Jan. 2003 - 05:03 bittemei
OK, I now know how Attributes work. If you've ever configured SCSI jumpers, it's kind of the same.

as a very simplified example:
x01 = Copyable(Copy command enabled)
x02 = Moveable(Cut command enabled)
x04 = Linkable(Create SC command enabled)

Any of these by itself enables just that one command.
If you set attributes to x03, you can Copy & Cut.
x05 would let you Create SC's and Copy, but not Cut.
x06 lets you Create SC's and Cut, but not Copy.
x07 lets you do all three.

So, using the table here for reference,

These are the Attributes we want, and their hex values:
SFGAO_FILESYSANCESTOR = 0x10000000
SFGAO_FOLDER = 0x20000000
SFGAO_FILESYSTEM = 0x40000000
SFGAO_HASSUBFOLDER = 0x80000000
SFGAO_HASPROPSHEET = 0x00000040
SFGAO_CANRENAME = 0x00000010

Total: 0xF0000050 (or "50 00 00 F0" if you're using binary)
This should give us a Renameable, Explorer-Browseable, Open/Save enabled, custom Folder with a (nonworking)Properties Sheet.

It doesn't work, not completely. Everything except being browseable in Explorer works, but it should be working too.

Phew. Gonna take a break on the attributes thing for awhile.
Mei
 
30 Jan. 2003 - 08:20 bittemei
Found it.
The "Attributes" and "CallForAttributes" values of this key:
[HKEY_CLASSES_ROOT\CLSID\{0AFACED1-E828-11D1-9187-B532F1E9575D}\ShellFolder]

prevent the explorer treeview. Set both values to "0x00000000" and you're set.

I updated the .reg file(from the first post) to show all the current changes.

w00t! :) The hard part's all done now. I still wanna make it idiot proof, but that's for laters.

Mei
 
01 Feb. 2003 - 02:34 spyder
Mei, this is great, now i have my download folder on "My Computer" , what i really like is tat you can have any icon you want and change the tooltip ;)
oh and i can copy it , cut it and make a shortcut of it :)
 
01 Feb. 2003 - 09:15 bittemei
cool. two questions:

1. Anybody tried this on something other than XP yet? Did it work, and if so, how well?

2. Anybody know of any interesting reg keys for property sheets? I know you can code your own (in .dll form) - but I was hoping there was a general-purpose one in a windows DLL that is configurable via the registry - like, say, the property sheet for .LNK files would be ideal.

I've been busy @work & school, will get back to looking for this sunday, hopefully.

Mei
 
06 Feb. 2003 - 09:25 saunders
Just wanted to mention that you can put your custom folder on your desktop also.
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace\{CLSID}]
Where CLSID is the number you used of course.

Also something else, I noticed that bittemei used Local Machine to add the icon to My Computer, but you can also use Current User (I used it for my folders because this is a family computer).

For example, I put my Server Root folder/icon in My Computer and on my Desktop but it doesn't show up on the rest of the family's, like this:

[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\MyComputer\NameSpace\{A0000000-0000-0000-0000-ABCDEF000000}]
@="Server"

[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace\{A0000000-0000-0000-0000-ABCDEF000000}]
@="Server"

Just thought I'd mention it, cus it seems like some interesting and handy stuff to know.

Oh, and you can also add extra functions as well, but I'm sure you guys now how to do that.
 
07 Feb. 2003 - 00:50 bittemei
@saunders - yeah, you can also add it to My Documents, the Control Panel, almost any other shell folder, just put it in the appropriate NameSpace key in the registry. Also which branch you use (CURRENT_USER/LOCAL-MACHINE) determines who it shows up for. If you do both parts of the hack, tho, it puts it there for all users, but leaves it diabled by default(that's what the second part is for).

I also wanted to point out some other stuff you can do with shdocvw.dll - pointing out specific system folders, subfolders under system folders(useful for always grabbing the right directory for multiple users), and finally, for executing a command when clicked(like what saunders did, but not in the CM).

For System Folders, This is the key that's different:
InitPropertyBag
 TargetSpecialFolder=REG_SZ:"<special folder number>"

For subfolders:
InitPropertyBag
 TargetSpecialFolder=REG_SZ:"<special folder number>"
 Target=REG_SZ:"<subdirectory name>"

For Commands: (this is a bit different, so I'll put the whole main key)
HKEY_CLASSES_ROOT
 CLSID
  {25892e17-80f6-415f-9c65-7395632f0223}=REG_SZ:"Test"
   InfoTip=REG_SZ:"Blah Blah Blah."
   DefaultIcon=REG_EXPAND_SZ:"default.ico"
  ShellFolder
   Attributes=REG_DWORD:0x00000000
  Shell
   Open
    Command=REG_EXPAND_SZ:"C:\mycommand.exe"

Mei
 
20 Feb. 2003 - 00:30 plastic
we're slow (...), I just created a blank page, Other UI parts/My computer, will display most credit goes your way, ofcourse. We used to have a downloadable regfile to add an item there, based on http://www.winguides.com/registry/display.php/73/ I'm sure you saw, you're using one of clsids they listed. You listed the problems with it, and your approach is definately better, but I'm wondering (just starting, nothing done yet), why you chose hex for the infotip and defaulticon part ? Is that XP acting up ?

[HKEY_CLASSES_ROOT\CLSID\{FD4DF9E0-E3DE-11CE-BFCF-ABCD1DE12345}\DefaultIcon]
@="C:\\Shell\\IconPhile\\Prime Download Folder.ico,0"

..is what we used to have.
 
21 Feb. 2003 - 04:23 bittemei
plastic: - yeah, I posted about this in the old forums, and somebody pointed me to that winguides page. I didn't like the method there tho, since all it was was opening a new explorer window targeted at the directory of your choice. As for why I chose hex, when I first started playing with the whole thing, I was using shell32.dll, and if I didn't use hex, the icon wouldn't show up. I just never bothered to switch back, since another benefit is when using hex for a path, you don't have to include "" if the path has spaces.

Mei
 
28 Feb. 2003 - 07:33 saunders
Hey bittemei, I was just trying to setup a folder to be optional on the desktop of individual users, like you did with My Computer, but I can't get it to work. I assumed you'd just have to put a DWORD value in
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons]
With a name of the CLSID and a value of 1, but it won't work. I can hide things in My Computer using this, but can't hide anything on the Desktop.

Just wondering what your experiences are in this.

*Edit*
I forgot to mention, I wrote a script in PHP to help me make my own custom folders easily. It doesn't make the folder options though.
Custom Folder Creator
 
01 Mar. 2003 - 03:51 Dirk_Diggler
Make your way here:-
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Desktop
Make a new Key and call it:-
Namespace
add a new Key to this called in this instance:-
{25892e17-80f6-415f-9c65-7395632f0223}

This will put the icon on the Desktop of the Current User only
 
01 Mar. 2003 - 07:10 saunders
Yeah I knew about that. But Bittemei had it setup so that you could add it to all users and then he created an option in the Tools>Folder Options to disable/enable it for each respective user, it was quite handy, AND, I figured it out.
Instead of just:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons]
It has to be in:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons\NewStartPanel]

I don't know if this is the proper way, or just a workaround though.

*Edit*
Uhhh ok... I just implemented this and it didn't work for me, although it worked fine on my little brother's profile.
Well, using Tweak UI I can turn it off and on for the desktop, but I can't figure out where in the registry it is.
 
01 Mar. 2003 - 07:34 saunders
EUREKA! I figured it out.
I feel kinda lame since you all probably know this already, but I'm going to post my findings anyway, so nyah. :P

So, to summarize what's up so far:
I created a custom folder (Music in this case) and I applied it to all the desktops using HKEY_LOCAL_MACHINE. I attempted to use Bittemei's method of creating an checkbox in the Folder Options to allow individual users to hide this icon but it didn't work out. So I posted here asking for help, then Dirk attempted to help and while he was helpful it wasn't what I was looking for.
THEN I thought I had it solved because of something I did while on my brother's profile and posted that I figure it out, and THEN it didn't work on my profile so I edited that post and said that I goofed up and was an all around dork.

BUT NOW I have it figured out.

Okay, so, in Bittemei's hack, he included the option to dis/enable the custom folder being shown in My Computer, and he used the key:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideMyComputerIcons] to accomplish this.
I tried using just:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons]
to hide the folder but it didn't work. But if you look in this key, there are two subkeys:
ClassicStartMenu
and
NewStartMenu
Now, as near as I can figure, if you're using the new XP start menu system then to hide your desktop icons you need to use the subkey of:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons\NewStartPanel]

But if you're using the classic start menu style (like I am) then you need to put the key in:
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons\ClassicStartPanel]

I'm looking again at Bittemei's InstallersOption.reg and just from the layout of file it doesn't look like you could implement one option to hide/show the icon on your desktop.
I'm hoping that Bittemei can prove me wrong, but otherwise as near as I can figure you'd have to have options like:
[] Show Music on Desktop with New Style Start Menu
[] Show Music on Desktop with Classic Style Start Menu

Oy, I hope enough of that makes sense that everyone who spends their time reading it can understand. I was a bit excited when I started.
 
01 Mar. 2003 - 23:52 plastic
Pretty cool, saunders. Still working on that page and will add that, thanks. That php script is awesome!
 
02 Mar. 2003 - 00:49 Explicit
Sooo, it's possible to add files to My Computer.... For the ones of us who don't feel like decifering this whole thread who knows how to do it and can write up an article? It would be greatly appreciated!
 
02 Mar. 2003 - 00:53 plastic
Hehe, compiling it, Explicit, but will possibly be even longer than this thread will sidestuff added etc. Bittemei's first few posts handle it, though, he pretty much figured it out from the start, but if you're in 98, follow the winguides method - http://www.winguides.com/registry/display.php/73/

Bittemei's new method is 100% better but won't work in 98.

 
02 Mar. 2003 - 02:36 saunders
Thanks plastic. Feel free to grab the script if you want to put it somewhere a little more official than "some guy's webpage." ;)
 
02 Mar. 2003 - 12:46 plastic
I was gonna mail you on that, cool :).
 
07 Mar. 2003 - 05:12 bittemei
@saunders
AFAIK, there's no way to change more than one value with each entry. You can, however, change the method from Checkbox to something else, and have it all dealt with by one key - look at HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\Thickets as an example.
Unfortunately, to get all the options for On/Off for both Classic and New, you would need four radio buttons, which would make the option much bigger than just two checkboxes.

Technically, you should be able to choose a 'Drop-Down' menu format, that should work. I'll have to look for an example of one to try though. You're doing great so far though - I never looked at the options for hiding/showing icons on the desktop at all.

I'll see if I can find a way to make a menu work in the advanced box.

Mei
 
07 Mar. 2003 - 06:53 saunders
@Mei
Thanks for the compliments, I'm just glad I'm digging up new information instead of rehashing stuff everybody knows all ready.

Btw, that key (HKEY_LOCAL_MACHINE\...\Folder\Thickets) doesn't exist for me.
 
16 Jul. 2005 - 01:27 des
hmm.. another useful but old topic.

i just created custom folder(to a folder) and custom links(to some progs) to my computer. works fine. :D

just only one question:
i use this command (explorer /root, c:\\something) to open the folder, but it opened in new window. how can i open this custom folder in the same window?
 
18 Jul. 2005 - 13:43 des
never mind. :D i did it with Shell Object Editor yet. LOL!
 
17 Aug. 2007 - 09:09 maniacOtaku
You can either do that or just substitute a folder for a drive.

"If you want to have a special attention to a folder you keep working on, why not substitute it as a drive? Weird question? No really. There is a small utility hidden in your WindowsCommand directory that call subst.exe which is brought over from old DOS. The syntax is simple.

To "rename" a folder into a drive, type in:

subst w: c:dataworkrecords

Now drive w will be officially your drive for working. Cool isn't it? To remove it, type:

subst w: /d

And there goes drive w. You can run subst.exe from DOS Prompt or Autoexec.bat. OK, other than giving you a shorter and manageable path, Windows will actually produce an independent recycle bin for it! Awesome if you want a separate workout from your normal drives."

It's way better than this I think.
 
17 Aug. 2007 - 19:30 DiosDePyro
Wow that's awesome. I never heard of that before maniacOtaku.

This is definitely something I'm saving for future reference.
 
04 Feb. 2008 - 19:52 tampajohn
Anyone still have a copy of the registry files referenced in bittemei's original post?
 
11 Aug. 2008 - 09:40 sameer619
You did a fine job mei, but unfortunately, your links to the registry files does not work for me. Can you post the contents in those files in here, so i can copy and save it as a .reg file. Don't you think it is much a better way?
 
11 Aug. 2008 - 16:44 des
ameer619:

you can do this easier with shell object editor:
http://www.tropictech.de/modules/PDdownloads/viewcat.php?cid=1
 
Please log-in to post.
You need to be logged in to post. To log-in, or to register an account go -there.
 
Options
Login | Help | Profile | User list | Display last  
 days 


../Msgboard/General customization/Custom Folders in My ComputerTop

xhtml 1.1