Help - Search - Members - Calendar
Full Version: Shortcutter - To create simple shortcuts using command line!
MSFN Forums > Unattended Windows Discussion & Support > Application Installs

   


Google Internet Forums Unattended CD/DVD Guide
Dirceu
Hello ppl!
This is my first utility with AutoIT.

Shortcutter 0.1 - Click to view attachment

May be useful for someone.
It creates a simple shortcut by given "target" and "link" paths, on command line.
If folder for link path doesn't exit, it will be created. That's a difference between this tool and MS "shortcut.exe" from Resource Server Kit, or from Optimum X.

Just read "shortcutter.txt".

Program Name: Shortcutter
Program Version: 0.1
Details: Creates a simple shortcut by the use of command line. If the path for the Link (.LNK) isn't valid / folders doesn't exist, they will be created! This utility was created mainly to use with silent installations (SFX) or similar stuff.
Language: AutoIT 3
Author: Dirceu de Oliveira Filho <d i r c e u AT g m a i l . c o m > A.K.A "Komakino" or "Komakin0" or "Repoman"
Website: http://repoman.free.fr | http://minor.free.fr


Usage: shortcutter.exe "<TARGET_PATH>" "<LINK_PATH>"

(World will be a better place if you put those quotes!)

<TARGET_PATH> - The file that the shortcut will refer (.EXE .DOC, etc)
<LINK_PATH> - The link file, with full path. (MUST END WITH .LNK)

Ex.
shortcutter.exe "%ProgramFiles%\My Program\My Program.exe" "%ALLUSERSPROFILE%\Start Menu\Programs\My Program\My Program.lnk"


FAQ

Q: Can i use enviroment variables?
A: Yes!

Q: Case sensitive?
A: Nope!

Q: Nothing happened! What's wrong?
A: Just make sure you typed the command line correctly AND have the right usage order! If the command line isn't correct, it won't work at all and won't even return an error message!

Q: Can i use it to create a shortcut from/for a network path address ?
A: Nope! And i don't know if it will able to do this some day. (At least i don't know yet!)

Q: Are you planning to add something in the future?
A: Maybe.

Q: Can i change the code, etc?
A: Go ahead! But don't forget to contact and give me some credits. I'll be pleased. smile.gif


TIP

You can use it with batch!
Oh, and throw "shortcutter.exe" at "%windir%\system32" folder if you want ("\$OEM$\$$\system32" for unattended installations!).




That's it.
welcome.gif
MHz
I've taken a guess at your source code as I have not downloaded it. Am I close?
CODE
If $cmdline[0] = 2 Then FileCreateShortcut($cmdline[1], $cmdline[2])

I would believe that workingdir and arguments could be a very useful addition.
Dirceu
Yep, $cmdline is there for sure.
Well, i'll give a shot for these other 2.




Google Internet Forums Unattended CD/DVD Guide

This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.