Link to home
Start Free TrialLog in
Avatar of adinarayanak
adinarayanak

asked on

how to set environmental variable through Install Script ?

hi all,
     I am using installShield professional2000 for preparing installshield of our project.
      there we need to set the environmental variables(like LOG_LEVEL=2);
On the dos prompt we can set using "set  LOG_LEVEL=2".

How can we do it through installShield script.

As far I know we can run any .exe file  through InstallShield by using windows API LanchApp (".exe","");

Please let me know if at all any way to set the LOG_LEVEL using IS.


regards,
Adinarayana,K
Avatar of adinarayanak
adinarayanak

ASKER

one more addition to that is

      While creating the installscript  through project wizard,I missed out the uninstall option somewhere.Now I added so many thing to the setup.rul file. At the end I tested my script.

     I could not able to  our project name in the add/remove programs after installation.There is one black line appearing.If I activate and click on the add/remove button on that panel then everything getting installed again.I could not able to uninstall that.
What may be the possible cause for that and How add unistall option for the existing installscript.It is urgent,please do it.

I will de thankfull to you.

regards,
AdinarayanaK
Hi Adi
For the first problem, use BatchAdd() or EzBatchAddString(). This will add the environment variable to "autoexec.bat" by default. You can specify the batch file.

If you are using BatchAdd() you have to open and close the batch file using BatchFileLoad() and BatchFileSave().

If you are using EzBatchAddString(), the batch file is automatically opened and closed for you.

Look in the IS help for details and/or examples.

Vicky
ASKER CERTIFIED SOLUTION
Avatar of V_Bapat
V_Bapat
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Dear V_Bapat,

reply to the first question is excellent.

regarding the second question,

     After installing a product through the installscript I should be able to see the file            " Uninst.isu" in TARGETDIR.But it is not getting appeared in the target directory.

What could be the reason ?  and why that FOLDER_NAME is not getting appeared in the add/remove programs ? I Hope I stated the question clearly.If not I will send the code with the next comment.

Hope U will solve my poblem.

regards
Adi.
Hi Adi
Uninst.isu is present in windows directory. Since that dir is in the path, the file is picked up from there.

Vicky
hi V_Bapat,
    I did the same as  you directed.The Shortcut is not getting created in the startup programs.

what could be the reason.

please let me know the solution as quick as possible.

regards,
Adi
the short cut is getting appeared in Start menu.When u click on uninstall it is giving the message that unable to locate uninst.isu. Could not uninistall.

what could be the reason. ?

Adi
the short cut is getting appeared in Start menu.When u click on uninstall it is giving the message that unable to locate uninst.isu. Could not uninistall.

what could be the reason. ?

Adi
If you post some code, I can understand what is happening better.

I would prefer to take the discussion to email. My email id is vicky@miel.mot.com.

Vicky