Hi,
What I'd like to do is register some sort of "run once" entry for all future *and* existing users that will create the shortcut
You could add a script in the Startup folder for the "All users" profile that will create a Quick Launch shortcut if one does not exist. This script will run each time a user logs in, but the shortcut will be created only once for all current and future users. A sample script:
Code: Select all
createQLShortcut("Shortcut name"),"C:\Program Files\App\app.exe",_
"C:\Program Files\App", "Description string"
Function createQLShortcut(strName, strTarget, strWkDir, strDesc)
Dim fso,strShPath
Set fso = CreateObject("Scripting.FileSystemObject")
Set WshShell = CreateObject("WScript.Shell")
Set colEnvVars = WshShell.Environment("Volatile")
strQLFolder = colEnvVars("APPDATA") &_
"\Microsoft\Internet Explorer\Quick Launch"
strShPath = strQLFolder & "\" & strName & ".lnk"
If (Not fso.FileExists(strShPath)) Then
' Create the shortcut
Set oShellLink = WshShell.CreateShortcut(strShPath)
oShellLink.TargetPath = strTarget
oShellLink.WorkingDirectory = strWkDir
oShellLink.Description = strDesc
oShellLink.Save
End If
End Function
Note that the conditional statement in line 14 is not absolutely necessary: if it is omitted and the shortcut already exists, the script will attempt to modify the properties for the existing shortcut.
Create a text file ("QLsh.vbs") containing the above script and modify it as necessary. Add this file in the Files and Folders page under "Start Menu -> Startup". If the package is installed per-machine, the script will be copied to the Startup folder for the "All users" profile.
Hope this helps.
Regards,
Ionut