PDA

View Full Version : can one also have a hardlink to a directory?


Michael Moser
February 10th 06, 01:53 PM
For convenience resaons I would like a specific directory to appear at
two locations.

The fsutil help only talks about files, not directories. Is it possible
to set hard links to directories, too?

Michael

Keith Miller MVP
February 10th 06, 04:21 PM
junction.exe from http://www.sysinternals.com

will do exactly that.

If you want to avoid 3rd party solutions, try a folder shortcut (not a .lnk file). They sort with
folders, cascade likes folders, etc.

To create a folder shortcut:

These are most easily created by opening two explorer windows, one to the user's start menu folder,
the other to the parent of the folder you wish to create a shortcut for. Right-click and drag the
target folder to the Start Menu folder and select 'Create Shortcut' after releasing the right mouse
button. The shortcut created in the Start Menu can then be moved wherever you like.

You know you have a folder shortcut because its type shows as 'Folder' and it only has a single tab
in its properties dialog.

--
Good Luck,

Keith
Microsoft MVP [Windows XP Shell/User]


"Michael Moser" > wrote in message
...
> For convenience resaons I would like a specific directory to appear at
> two locations.
>
> The fsutil help only talks about files, not directories. Is it possible
> to set hard links to directories, too?
>
> Michael
>

Michael Moser
February 14th 06, 09:14 AM
Great! Thanks!

This would be even better with some visual clue. Is there a way to use a
special icon for these links? E.g. something like the folders beneath
the start menu, that show a special folder icon overlayed with an image
of an opened window?

Michael


"Keith Miller MVP" > wrote in message
...
> junction.exe from http://www.sysinternals.com
>
> will do exactly that.
>
> If you want to avoid 3rd party solutions, try a folder shortcut (not a
> .lnk file). They sort with
> folders, cascade likes folders, etc.
>
> To create a folder shortcut:
>
> These are most easily created by opening two explorer windows, one to
> the user's start menu folder,
> the other to the parent of the folder you wish to create a shortcut
> for. Right-click and drag the
> target folder to the Start Menu folder and select 'Create Shortcut'
> after releasing the right mouse
> button. The shortcut created in the Start Menu can then be moved
> wherever you like.
>
> You know you have a folder shortcut because its type shows as 'Folder'
> and it only has a single tab
> in its properties dialog.
>
> --
> Good Luck,
>
> Keith
> Microsoft MVP [Windows XP Shell/User]
>
>
> "Michael Moser" > wrote in
> message
> ...
>> For convenience resaons I would like a specific directory to appear
>> at
>> two locations.
>>
>> The fsutil help only talks about files, not directories. Is it
>> possible
>> to set hard links to directories, too?
>>
>> Michael
>>
>

Keith Miller MVP
February 15th 06, 06:10 PM
There's no way to change the default that I can find. The shortcut will normally take on the icon
of the folder it references.

You can modify the icon manually, it goes like this:

The folder shortcut is actually a file folder containing 2 files:
desktop.ini
target.lnk

To see these, use 'dir' from a command prompt. To view in explorer, first use the 'attrib -r'
command to remove the read-only attribute from the folder.

So if remove the read-only attribute from the folder, you can right-click the target.lnk shortcut
and change its icon from its properties dialog. When you're done, set the read-only attribute back
and the folder shortcut will display the icon you assigned to target.lnk.

It's a somewhat cumbersome process, I know :-). But that could be overcome via scripting.


--
Good Luck,

Keith
Microsoft MVP [Windows XP Shell/User]


"Michael Moser" > wrote in message
...
> Great! Thanks!
>
> This would be even better with some visual clue. Is there a way to use a
> special icon for these links? E.g. something like the folders beneath
> the start menu, that show a special folder icon overlayed with an image
> of an opened window?
>
> Michael
>
>
> "Keith Miller MVP" > wrote in message
> ...
> > junction.exe from http://www.sysinternals.com
> >
> > will do exactly that.
> >
> > If you want to avoid 3rd party solutions, try a folder shortcut (not a
> > .lnk file). They sort with
> > folders, cascade likes folders, etc.
> >
> > To create a folder shortcut:
> >
> > These are most easily created by opening two explorer windows, one to
> > the user's start menu folder,
> > the other to the parent of the folder you wish to create a shortcut
> > for. Right-click and drag the
> > target folder to the Start Menu folder and select 'Create Shortcut'
> > after releasing the right mouse
> > button. The shortcut created in the Start Menu can then be moved
> > wherever you like.
> >
> > You know you have a folder shortcut because its type shows as 'Folder'
> > and it only has a single tab
> > in its properties dialog.
> >
> > --
> > Good Luck,
> >
> > Keith
> > Microsoft MVP [Windows XP Shell/User]
> >
> >
> > "Michael Moser" > wrote in
> > message
> > ...
> >> For convenience resaons I would like a specific directory to appear
> >> at
> >> two locations.
> >>
> >> The fsutil help only talks about files, not directories. Is it
> >> possible
> >> to set hard links to directories, too?
> >>
> >> Michael
> >>
> >
>

Google