Create shortcuts in the command line
Hello!
I just spent an afternoon on my XP to try to create shortcuts (called "symbolic link" under UNIX) with the command line.
No results :crybaby:
My problem is: I really need to create shortcuts (from python, which is normally filled launch any command line tool) with a partial mirror script Debian deposit before work (at least ) under linux and windows!
Can anyone help me?
thank you for your answers,
Re: Create shortcuts in the command line
I think you should go through a VB script.But I even also heard that similar to the built-in START command, in addition to normal, minimized and maximized an applicatin you could also use an commands from Command line.
Re: Create shortcuts in the command line
Ok, thank you very much!
The solution is not necessarily ideal, but I probably troubleshoot ... Again thank you
Re: Create shortcuts in the command line
With WSH (you should be able to call via Python I think):
Code:
WshShell = CreateObject ( "WScript.Shell")
strDesktop = WshShell.SpecialFolders ( "Desktop")
oMyShortcut = WshShell.CreateShortcut (strDesktop + "\ Sample.lnk")
oMyShortcut.WindowStyle = 3 & & 7 = Minimized Maximized 4 = Normal
oMyShortcut.IconLocation = "C: \ myicon.ico"
OMyShortcut.TargetPath = "% windir% \ notepad.exe"
oMyShortCut.Hotkey = "ALT + CTRL + F"
oMyShortCut.Save
Re: Create shortcuts in the command line
Ok, thank you all.
I will (initially) to use the command line tool proposed by Paramartha, before getting into the WSH (or outright IShellLink via PyWin32 ...)
Regards