This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: Setup Prerequisite folder structures
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
‎Sep 12, 2014
04:58 PM
Setup Prerequisite folder structures
Is setup prerequisites still not able to have a folder structure? I have an install I need to add to my project and of course they have it uncompressed with a bunch of files and folders. I tried to include in Disk 1 but I really wanted the prerequisite to be contained from the setup.exe. I'm currently writing a batch file to recreate the folder structure so I can run the installer.
Cheers!
Cheers!
(5) Replies
‎Sep 15, 2014
06:42 PM
I have a batch file that recreates the folder structure. However I have one other issue. I'm trying to add a shortcut but the prerequisite editor only adds what the shortcut's target is.
For example, the shortcut is named "Shortcut to User Data Properties" with a target of "C:\WINDOWS\explorer.exe "shell:AppData\Label Printer"
The editor wants to add explorer.exe from the windows folder.
WHY? It should just add the .lnk file and not look at its target. :confused:
I had to hand edit the prq and take away the windows explorer link and have it add the actual file. I opened the prq again in the editor and its listing the correct file.
For example, the shortcut is named "Shortcut to User Data Properties" with a target of "C:\WINDOWS\explorer.exe "shell:AppData\Label Printer"
The editor wants to add explorer.exe from the windows folder.
WHY? It should just add the .lnk file and not look at its target. :confused:
I had to hand edit the prq and take away the windows explorer link and have it add the actual file. I opened the prq again in the editor and its listing the correct file.
‎Sep 16, 2014
06:52 PM
Another strange thing.....
The installer that I packaged up as a prerequisite and then wrote a batch file to recreate the folder structure it expects works fine. Except when the main installer quits or completes a registry key for the prerequisite gets deleted. I put a pause in the batch file so it would recreate the folder structure and then stop. I tested the installer from this location both manually/interacting or using the /S /v/qn command line options. I confirmed the registry key is there for both manual and silent. However when I quit or complete my main installer the key gets deleted. This causes the prerequisite installer to fail when being uninstalled cause its trying to unregister the dll. I get this error:
Error 1905. Module {path to the file} failed to unregister. HRESULT -2147220472. Contact your support personnel.
The prerequisite installer will uninstall correctly if I don't quit or complete the main installer. Why would my main installer delete a registry key to the prerequisite installer? I haven't tried to register the DLL myself in the main installer yet. I thought it was because I was doing it silently but it appears to be not the case. I wonder if there are other registry keys that get removed??
The installer that I packaged up as a prerequisite and then wrote a batch file to recreate the folder structure it expects works fine. Except when the main installer quits or completes a registry key for the prerequisite gets deleted. I put a pause in the batch file so it would recreate the folder structure and then stop. I tested the installer from this location both manually/interacting or using the /S /v/qn command line options. I confirmed the registry key is there for both manual and silent. However when I quit or complete my main installer the key gets deleted. This causes the prerequisite installer to fail when being uninstalled cause its trying to unregister the dll. I get this error:
Error 1905. Module {path to the file} failed to unregister. HRESULT -2147220472. Contact your support personnel.
The prerequisite installer will uninstall correctly if I don't quit or complete the main installer. Why would my main installer delete a registry key to the prerequisite installer? I haven't tried to register the DLL myself in the main installer yet. I thought it was because I was doing it silently but it appears to be not the case. I wonder if there are other registry keys that get removed??
‎Sep 17, 2014
08:54 AM
Without knowing the registry key, I'm not even sure how to guess. However since you do know the registry key, you could watch the key with a tool like Process Monitor to look for other hints, or search for references to it in any relevant projects. For what it's worth, the only definition I found associated with the HRESULT you mentioned is MS_E_SOURCEALREADYDEFINED, but unless that makes sense to you, it's probably the wrong interface (that HRESULT's meaning is interface-dependent).
As far as adding the .lnk file or what it points to, it's an oversight and due to using defaults of the file browse dialogs, but it may be correct. It's fairly rare for a shortcut to be useful when copied to another machine in a different environment, so supporting the inclusion of .lnk files in a prerequisite seems like it would be of quite limited use. If we can clarify the reasons that it might be useful, we can certainly turn this into a enhancement request; in the mean time, it sounds like you found an effective workaround by editing the .prq file directly.
As far as adding the .lnk file or what it points to, it's an oversight and due to using defaults of the file browse dialogs, but it may be correct. It's fairly rare for a shortcut to be useful when copied to another machine in a different environment, so supporting the inclusion of .lnk files in a prerequisite seems like it would be of quite limited use. If we can clarify the reasons that it might be useful, we can certainly turn this into a enhancement request; in the mean time, it sounds like you found an effective workaround by editing the .prq file directly.
‎Oct 17, 2014
04:36 PM
Thanks Michael!
I ran process monitor on it but it didn't really tell me much. I see a bunch of Reg executions from the printer driver installer. Then once I close that I can my installer.exe try to read the particular registry key that goes missing. Is my main installer some how keeping track of the printer driver installer? The printer driver is "Seiko Smart Label Printer 7.1.1 R2". The registry key I know of that goes missing is:
[HKEY_CLASSES_ROOT\TypeLib\{521782C8-2A7C-4F4E-ACF9-F054DE73B10E}
I can manually install the printer driver then my installer with no trouble. This is undesirable. I can export all the registry entries then maybe using a custom action to let me know if the printer driver gets installed and then push those registry entries back in.
I ran process monitor on it but it didn't really tell me much. I see a bunch of Reg executions from the printer driver installer. Then once I close that I can my installer.exe try to read the particular registry key that goes missing. Is my main installer some how keeping track of the printer driver installer? The printer driver is "Seiko Smart Label Printer 7.1.1 R2". The registry key I know of that goes missing is:
[HKEY_CLASSES_ROOT\TypeLib\{521782C8-2A7C-4F4E-ACF9-F054DE73B10E}
I can manually install the printer driver then my installer with no trouble. This is undesirable. I can export all the registry entries then maybe using a custom action to let me know if the printer driver gets installed and then push those registry entries back in.