This trick will allow you to edit shortcut properties in Windows.
- Add Windows Script Host Object Model reference under the COM tab. To do that, right click on References in Solution Explorer and then Add Reference.
- Insert the using statement:
using IWshRuntimeLibrary;
- Here is the sample code
WshShell shell = new WshShell();
IWshShortcut link = (IWshShortcut)shell.CreateShortcut(filename);
Now you can set and get various shortcut properties via methods in the link object. Be sure to call the Save()
to save changes you made.
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.