Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.
Keywords: LNK
I do not think it is possible. Once the exe is launched, then all information about which shortcut launced it is lost.
If you modify your shortcuts, they could pass in some kind of parameter which might help you find them.
A shortcut is run by a call to Shell32.dll, which digs out the information from the shortcut and runs the .exe, .com, .whatever, with the appropriate settings, and, I presume, changing to the appropriate directory. There are no registry settings that will tell you this information, or tell you which shortcut was run. You would have to find a way to poll shell32 calls as they were made in order to determine this information.
Good luck-- it looks like a humongous task. It might be easier to run a script using the searcher extender and create a database of every .lnk file that exists.
Article ID: W13846
Filename: Get Shortcut Info of Current Shortcut.txt
File Created: 1999:04:15:16:56:46
Last Updated: 1999:04:15:16:56:46