I don't know of a batch command which can create a shortcut. However, you could work round this:
1. Create a shortcut to your database, in the same folder as the database. Name this something like:
StartSystem1.lnk
(shortcuts have the file name extension .LNK, but this is very difficult to see even through Explorer!)
2. Write a .BAT or .CMD file which contains:
Code:
COPY StartSystem1.lnk C:\WINNT\Profiles\%USERNAME%\Desktop
This assumes the batch file is in the same folder as the shortcut file. If not, use:
Code:
COPY [PathToShortCut]\StartSystem1.lnk C:\WINNT\Profiles\%USERNAME%\Desktop
Notice the variable %USERNAME% - this is replaced by the environment variable USERNAME when the batch or command file runs.
3. This assumes, of course, that your workstations have a variable like this set. Open a command window and type:
... to see a full list of environment variables, e.g.
Code:
USERDOMAIN=MYSERVER
USERNAME=bob.stubbs
USERPROFILE=C:\Documents and Settings\bob.stubbs
windir=C:\WINNT
Use whatever your user name variable is called here, in your batch file, and this should work.
4. You can use this technique to post shortcuts to the user's desktop, the Startup menu etc.
5. Remember that if there are any spaces in either the source or destination path names, you must enclose them in double quotes:
Code:
COPY "My Source Folder\Filename.txt" "My Target Folder"
This is because the command interpreter looks for spaces between the word COPY, the source folder and the target folder. Any other spaces will confuse it!
I hope that this helps.
Bob Stubbs