Adding Command-Line Switches To Windows Shortcuts
- by jaytea
Is there a way to, in general, create a Windows shortcut to a file and instruct Windows to pass certain switches to the application before passing the filename?
For example: I have an Excel file, abc.xlsx. If I want to create a shortcut to open this file read-only, I would change the target to "C:\Program Files\Microsoft Office\Office12\EXCEL.EXE" /r abc.xlsx, but this fails when another person on my network opens the shortcut and their EXCEL.EXE is not in that same folder.
Surely there's a way to tell Windows to pass the /r switch without supplying the path/filename of the application that is supposed to open the file?