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: Changing IISROOTFOLDER
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 13, 2016
07:38 AM
Changing IISROOTFOLDER
I have trouble while installing components for IIS.
I have build a dialog, where user can select the IIS WebSite.
Then in InstallScript, after the dialogs i call:
MsiSetProperty(ISMSI_HANDLE, "IISROOTFOLDER", WebSitePath);
The result is, that some components install in the correct selected WebSite path, and others will be installed in the default wwwroot.
Components that should install to the root of my web app are installed by mistake under c:\inetpub\wwwroot\my.web.
Components that should install in subdirectories of my web app are installed correctly under c:\inetpub\wwwroot_site2\my.web\App_Data.
Do you have any clue why this happens?
Why is changing the IISROOTFOLDER with MsiSetProperty not handled correctly anywhere?
I have build a dialog, where user can select the IIS WebSite.
Then in InstallScript, after the dialogs i call:
MsiSetProperty(ISMSI_HANDLE, "IISROOTFOLDER", WebSitePath);
The result is, that some components install in the correct selected WebSite path, and others will be installed in the default wwwroot.
Components that should install to the root of my web app are installed by mistake under c:\inetpub\wwwroot\my.web.
Components that should install in subdirectories of my web app are installed correctly under c:\inetpub\wwwroot_site2\my.web\App_Data.
Do you have any clue why this happens?
Why is changing the IISROOTFOLDER with MsiSetProperty not handled correctly anywhere?
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2016
05:14 AM
Put a MessageBox or Sprintf statement in your InstallScript code to see what the value of WebSitePath is. You may find that it is blank. How is your CA executed? You need to do a little work to make properties available to a deferred CA. Where is your Custom Action sequenced? It may be too late. Basic MSI or InstallScript MSI project?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 18, 2016
07:18 AM
With a MessageBox i can see, my WebSitePath is set correctly to the directory i want.
I have a InstallScript MSI Project, and i do MsiSetProperty(ISMSI_HANDLE, "IISROOTFOLDER", WebSitePath) in the OnFirstUIBefore() method, just after the last dialog was called.
I have got a workaround by calling MsiSetProperty for all my directory variables, which depend directly or indirectly from IISROOTFOLDER.
It seems to me, that directory variables are resolved at different times, and i don't understand where and when.
If you mean CustomAction with CA, then no, i have no custom action, i'm in the OnFirstUIBefore().
Currently i have no experiences with CustomActions, i'm doing all my stuff in the scripts and the scripted events of features.
What would be the way to tell the installer the value of a variable, if i would use a CA?
I have a InstallScript MSI Project, and i do MsiSetProperty(ISMSI_HANDLE, "IISROOTFOLDER", WebSitePath) in the OnFirstUIBefore() method, just after the last dialog was called.
I have got a workaround by calling MsiSetProperty for all my directory variables, which depend directly or indirectly from IISROOTFOLDER.
It seems to me, that directory variables are resolved at different times, and i don't understand where and when.
If you mean CustomAction with CA, then no, i have no custom action, i'm in the OnFirstUIBefore().
Currently i have no experiences with CustomActions, i'm doing all my stuff in the scripts and the scripted events of features.
What would be the way to tell the installer the value of a variable, if i would use a CA?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 19, 2016
08:07 AM
Variable names that you want to be public must be in ALL UPPERCASE.
Setting variable in CA would be same as you are doing now (InstallScript code) or if that is all you need to do you could use a 'Set Property' CA. That would be found under 'Behavior and Logic', 'Custom Action'. Right click on 'Custom Actions' and select 'New Set Property'.
Setting variable in CA would be same as you are doing now (InstallScript code) or if that is all you need to do you could use a 'Set Property' CA. That would be found under 'Behavior and Logic', 'Custom Action'. Right click on 'Custom Actions' and select 'New Set Property'.