I have folders filled with file shortcuts. I use them to organize files in different ways without needing to have duplicates of the original (and quite large) files.
How “smart” are the shortcuts? Meaning, if I change the name and/or location of the original file, does the shortcut automatically update itself, or did I just render the shortcut invalid and need to update or recreate the shortcut?
Also, any idea how I can create shortcuts for multiple files at once to a location other than the desktop? I managed to do it once, completely by accident, and I have no clue how I did it; couldn’t do it again.
It depends. If the shortcut is just broken, Windows searches to see if it kind find the target. How hard it searches, and how it searches, depends on the version of windows and the nature of the link.
If you are running the Distributed Link Tracking Client, it
"Enables client programs to track linked files that are moved within an NTFS volume, to another NTFS volume on the same computer, or to an NTFS volume on another computer. If this service is stopped, the links on this computer will not be maintained or tracked. "
And if you are running the Distributed Link Tracking Server, it
"Enables the Distributed Link Tracking Client service within the same domain to provide more reliable and efficient maintenance of links within the domain. "
The effect is:
The distributed link tracking service tracks link sources for shell shortcuts and OLE links within NTFS file system volumes. The link client can fix a broken link with updated information on the new location of the link source."
Even without link tracking, Windows (depending) may do a simple file search for broken shortcuts. But although shortcuts look roughly the same, and act roughly the same, there is actually a heap of different things that are ‘shortcuts’, which are completely different to each other.
I don’t know about link tracking, but I did find something interesting out in Windows 10 at least. If you make a shortcut to a folder, you can actually drag & drop files on the folder shortcut and it’ll move them into that folder as if it was a folder.
For all I know, it may have done that since Windows 3.1, but I didn’t find that out until about a year ago.
Definitely not that long, as Windows 3.1 didn’t even have shortcuts. They were invented for the new Desktop in Windows 95. The Desktop was just a special folder in the new Windows Explorer, so it needed a way to link to files in other folders. (And a folder is really just a special type of file.)
I just tried creating a file in an NTFS folder, then creating a hard link, then moving the original file to a different folder, and the other link was still OK. Not that that solves the original problem of needing a shortcut which then does not get updated.
How do you even create shortcuts on the desktop?. If you have Explorer open to some folder full of files, and you select several of those files and right-click [Create shortcut], the new shortcuts will be placed in the same folder as the files, not on the desktop.
So what process are you trying to describe?
Or maybe a better question is: what’s your actual end goal? You may well be doing something the hard way and asking us how to do steps 3 and 4 of a fundamentally flawed approach to solving your actual problem.
That’s not been my experience. When I highlight a group of files, right-click, then click on “create shortcut,” a dialog box appears that reads (paraphrasing): “shortcut cannot be created in this location would you like to place them on the desktop?” with Yes/No buttons underneath. Pressing “yes” creates all the shortcuts on the desktop, and pressing “no” cancels the whole procedure.
If I click on just a single file and click “create shortcut,” it creates it and places it in that same folder like you describe.
I just want to be able to highlight a bunch of different files and create shortcuts for them in a different folder. I’ve been having them go on the desktop then highlight them all and move them to the folder I want them to be in, but I’m just wondering if there’s a way to just have them created directly in that other folder without the middle steps.
The way to create shortcuts to multiple files is to select the files, then copy. Then go to the folder where you want your shortcuts, right click, and select “Paste shortcut”. It will create a shortcut for each file that was selected.
Ahh thank you. That’s the fallback UI when you don’t have access rights to the folder to create shortcuts. They offer to create desktop shortcuts as “the next best thing”.
There are also special situations involving places that look like disk folders but aren’t really that have the same result; you can’t write there, so instead they offer for you to write to the desktop.
Just out of curiosity (Shoeless solved my problem), was I getting this because the source files are on an external drive? (the target folder is on the same drive)
Windows shortcuts are not hardlinks. They’re more analogous to unix/POSIX softlinks, which can also become abandoned if their target is moved or removed.
Hardlinks are simply a second directory entry pointing at the same filesystem object.
Right, they are not at all shortcuts or symlinks, but what they will do is still access the file even after the original is moved or removed, so maybe that’s good enough for the OP. The utility above should have an option to create hard links (or shortcuts or whatever you want) to all selected files and dump them in the folder you specify.
Yeah, with a hardlink, you could even completely delete the “original”, and the new link would still work. And I put “original” in quotes, because once a hardlink is created, there’s no way to distinguish between the two.
One issue with hardlinks is that they render ambiguous the question of “how much disk space is taken up by the contents of a folder”, and in general interfere with the abstraction of a file being “located in” a folder. I think that’s probably why Windows steers away from them.
My (perhaps outdated) understanding is that shortcuts don’t actually do that.
When you move or rename a file targeted by a shortcut the shortcut is none the wiser. It now points to an absent file.
When you try to dereference the file through the shortcut and Windows finds the file is gone, Search kicks in to try to find some file that’s probably the one the shortcut used to point to. Often that succeeds, and so quickly and accurately the user never knows what really happened. Other times it fails, or worse yet, finds the wrong file.
I just tested, and by Gates, you’re right. I created a shortcut, then moved the target file (by mouse-dragging it in explorer), then looked at the shortcut properties. It still pointed to the old location.
But double-clicking the shortcut opened the file from the new location (and updated the shortcut so it now points to the new location).