Jump to content

Need a shortcut to a FOLDER


Recommended Posts

I have an installer that also creates a subdirectory called 'TestData' in the same folder as the exe. It would be great if the installer could create a shortcut to that folder on the 'All Users' desktop.

Here is the problem. The program will be installed on a customer's computer. At certain points in the program a password is required. The default password, or the customer password (if he changes it), is encrypted into a file in the same directory as the exe. During installation a file is created with the default password. Also, up until now I would create a shortcut to the 'TestData' folder (where all customer test data is saved) on the desktop.

I was asked what would happen if the customer lost, or forgot, his password. In this case they would be able to backup their data, completely uninstall the program, and reinstall it, restoring the default password. I do not know if the uninstaller would delete the shortcut or if it would become 'broken' during the uninstallation and would not want to have to go to the customer's site to re-create it.

Is there a way for the installer to create it? I have tried the Shortcuts section in the Installer Build specifications, but that will only create shorcuts to files (why?).

Any assistance appreciated.

Roy

Link to comment

You could alway go through the windows API calls, but that's usually a bit troublesome at best.

An easy workaround is to create an internet shortcut instead, which is just an *.ini file, with *.url extention.

The plain format is as follows:

[internetShortcut]

URL=c:\windows

IconFile=C:\WINDOWS\system32\SHELL32.dll

IconIndex=4

HotKey=0

IDList=

See attached VI for details...

Link to comment

QUOTE(Dirk J. @ Mar 23 2007, 03:36 AM)

You could alway go through the windows API calls, but that's usually a bit troublesome at best.

An easy workaround is to create an internet shortcut instead, which is just an *.ini file, with *.url extention.

The plain format is as follows:

[internetShortcut]

URL=c:\windows

IconFile=C:\WINDOWS\system32\SHELL32.dll

IconIndex=4

HotKey=0

IDList=

See attached VI for details...

Thanks, Dirk. Two questions. 1. Could you send me that example in 8.01? B. How do you make it work during the installation (not execution)?

Roy

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.