[wpkg-users] Old Feature Request / Perhaps New Idea
Heiko Helmle (horiba/eu)
heiko.helmle at horiba.com
Wed Feb 17 14:47:59 CET 2010
Thanks for your reply -
> > Well - the start-menu part is saved in the registry:
> \Explorer\Shell Folders\Common Programs
> > If WPKG could expand some of those paths ("Common Desktop" would
> > also be very useful), this could simplify lots of install scripts.
> You may want to open a command prompt and execute the SET command.
> You will notice the following environment variables: USERPROFILE and
... Which expand only to a part of the needed path. And the part missing
is localized. I already searched all the standard env-variables for useful
stuff, but localization bites me all the time.
> The ALLUSERSPROFILE will point the root folder for the common
> desktop, so using %ALLUSERSPROFILE%\Desktop will work on any
> localization, since it works for me on German and English localizations.
... As long as the Desktop ist in the path ".\Desktop". I didn't check
(yet) but I bet, French XP might not be called "Desktop".
And even in ENU/DEU it doesn't work for the Start Menu - but the registry
entry "Common Programs" and "Common Start Menu" always points to the
And for added bonus - those entries work in Win7 - for shortcuts you won't
have to check what Win-Version you're on - just expand the registry
you can workaround this with a vbscript using something like this:
set oShell = WScript.CreateObject("Wscript.shell")
oshell.run "%COMSPEC% /C del " & commonPrograms & "\shortcut.lnk", 1, true
but would'nt it be nice just to use
<install cmd="%COMSPEC% /C del %COMMON_START_MENU%\shortcut.lnk" />
Folders\Common Startup" value="STARTUP" />
<install cmd="%COMSPEC% /C del "%STARTUP%\StupidApp.lnk" />
> On the other hand you can create JS scripts to create shortcuts, see
> http://wpkg.org/Category:Utility_Scripts for an example of such a
> script for desktop shortcuts.
Well - this won't help if you want to delete shortcuts, or move them
around, or do something in the global appdata (which is different on XP
Most Installers already create shortcuts - but often too many or in
wrong/unwanted places. Or place stuff in the Startup-Folder.
I just thought this might be a pretty simple (and possibly useful)
addition, that could save lots of external extra-scripting.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the wpkg-users