cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Fyodor
Level 3

Virtual directory

Hi,
I need help!
Does anybody tried to create WebSite or virtual directory through IDE pane so that the names will be configurable during runtime? I.e putting some variables instead of real names in the pane.

Thank you
P.S I am using IS 2008 professional and my project is Script Project.
Labels (1)
0 Kudos
(5) Replies
DebbieL
Level 17

The following help topic has an example of how to do something like that:
Using InstallScript Text Substitution to Dynamically Modify IIS Settings

The example shows how to end users specify the user name. However, you could easily use text substitution for the name of a Web site or virtual directory instead of the user name.

I hope that helps.

Debbie Landers
Macrovision Corporation
0 Kudos
Fyodor
Level 3

Hi,
I did exactly what is written in the help but it did not work somehow!
I did not find any information about this neither in release notes nor in the bug bulletin. May be it is error in the help and some other sdditional thing should be done?
I wonder if there anybody that performed the same task and it worked?

Thank you

Fyodor.
0 Kudos
DebbieL
Level 17

Hmm. I followed the instructions in the help, and it worked fine for me. Can you post the InstallScript code that you used, and maybe a screen shot of what you have in the IIS view? Maybe that would help troubleshoot the issue.

Thanks,
Debbie Landers
Macrovision Corporation
0 Kudos
Fyodor
Level 3

Debbie, thank you very much for your patience!
Here I paste the code fragment from my setup.rul file:

Dlg_SdWelcome:
//{{IS_SCRIPT_TAG(Dlg_SdWelcome)
nResult = SdWelcome( szTitle, szMsg );
szOpt1 = "Some_Name";
szOpt2 = "Some_User";
TextSubSetValue("", szOpt1, TRUE);
TextSubSetValue("", szOpt2, TRUE);
//}}IS_SCRIPT_TAG(Dlg_SdWelcome)
if (nResult = BACK) goto Dlg_Start;

VD is the name of virtual directory, and the USER is the user for directory security. None of them is changed during installation. The only variable that getting changed is Local Path i.e. the variable is changed to the real path.
I also include the screenshot from the IIS view of InstallShield. In the left lower corner the information about InstallShield.
Thank you.

Fyodor.
0 Kudos
venkatprasanth
Level 2

Dude,
Use MsiSetProperty(ISMSI_HANDLE,'VDIRNAME',szVDirName);
the single quotes around the property VDIRNAME does the magic.

I dont know how that TextSubSetValue() is working for some people.

Set the vdir name as [VDIRNAME];
Create the property VDIRNAME in the property table.
After u get the input from user,read it into szVDirName and call the above function.
This works.
0 Kudos