Reputation: 900
When I try to expand a network drive from the 'Browse' button on the 'Select Destination Location' setup page I get a 'refers to a location that is not available' error (see first screenshot), the network drive icons don't display either.
The network drive permissions allow all users read/write drive access and other apps do not have the same problem (the dialog in the second screenshot was generated by a 32-bit app calling the SHBrowseForFolder API).
The environment is Windows 8 (64-bit) with all updates as of 16-Jul-2013 running as a VirtualBox 4.2.16 client. The setup has been compiled with the latest version of Inno Setup (5.5.3 (a)).
The problem is exhibited by both Samba and Windows shares. Windows 7 and XP do not have the same problem. I haven't tested it on a dedicated (non VirtualBox) Win8 PC.
Any help would be greatly appreciated.
Upvotes: 4
Views: 1484
Reputation: 21
This problem annoyed me to for quite a while as well, until I found an easy solution:
In the registry just set [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System] "EnableLinkedConnections"=dword:00000001
reboot, and be done with it.
Over the background and possible drawbacks read here and here
When it comes to Inno Setup, one can also follow this approach: Make Inno Setup installer request privileges elevation only when needed. Esp. when one does not want to ask customers to change this registry key. I am doing it like that and it works quite fine.
Upvotes: 1
Reputation: 13030
By default Windows does not cache login credentials between elevated and non-elevated processes. You logged into the server and mapped the drive letter as a non-elevated user; this is not available to an elevated process such as an installer.
You can set PrivilegesRequired=lowest
in the [Setup]
section to prevent elevation and keep network drives available; however bear in mind that doing this will also prevent access to any admin-required locations or functionality on the local machine.
If you are creating a "pure" network installer (that does not install any local files), you may also wish to use settings like Uninstallable=no
. Alternatively, you could redesign your installer to run locally on the server machine instead.
Upvotes: 2