Where should call Custom Action for Set Environment Variable

Having trouble running Advanced Installer? Got a bug to report? Post it all here.

Where should call Custom Action for Set Environment Variable

Postby udayk » Tue Feb 07, 2012 11:55 am

Hi Team,

Can any one please tell me about for which type of standard action is good for set Environment variables through custom action.

I tried WriteEnvironmentStrings,Commit and CostFinalize,
the above 3 standard actions are not good for Set Environment Variables through Custom action.

can any once please help me on this issue.

Thank you,
Udayk.
udayk
 
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Re: Where should call Custom Action for Set Environment Vari

Postby udayk » Tue Feb 07, 2012 1:25 pm

Thank you Mihai,

I solved this in another process, its working fine.

But, i set environment variables of JAVA_HOME and Path, but the service is unable to find JAVA_HOME and Path.
I think it requires restart will be needed after setting Environment variables through CA, How should i restart System after setting Environment variable through CA, and continuing next process.

Can you please reply about requirement.

Thank you,
Mihai.
udayk
 
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Re: Where should call Custom Action for Set Environment Vari

Postby mihai.petcu » Tue Feb 07, 2012 3:23 pm

Hi Udayk,

Why don't you use our Environment Variables Page functionality regarding this?
http://www.advancedinstaller.com/user-g ... ables.html

However, please keep in mind that a System Environment Variable cannot be referenced by the installation process during which it's created. A solution you can try is to add a pre-install prerequisite that creates the environment variable instead.

All the best,
Mihai
Mihai Petcu
Advanced Installer Team
http://www.advancedinstaller.com/
mihai.petcu
 
Posts: 3452
Joined: Thu Aug 05, 2010 8:01 am

Re: Where should call Custom Action for Set Environment Vari

Postby udayk » Wed Feb 08, 2012 6:22 am

Mihai,

You said a solution to add a pre-install prerequisite that creates the environment variable instead.

Ok, but where should i create Pre-install prerequisite in AI, can you please tell me breifly.

Thank you,
Udayk
udayk
 
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm

Re: Where should call Custom Action for Set Environment Vari

Postby mihai.petcu » Wed Feb 08, 2012 11:34 am

Hi Udayk,

where should i create Pre-install prerequisite in AI

From the Prerequisites page:
http://www.advancedinstaller.com/user-g ... sites.html

Best,
Mihai
Mihai Petcu
Advanced Installer Team
http://www.advancedinstaller.com/
mihai.petcu
 
Posts: 3452
Joined: Thu Aug 05, 2010 8:01 am

Re: Where should call Custom Action for Set Environment Vari

Postby udayk » Tue Feb 14, 2012 1:07 pm

Thank you mihai,

I resolve this issue.
udayk
 
Posts: 126
Joined: Thu Jan 19, 2012 12:30 pm


Return to Common Problems

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 1 guest