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
- :
- InstallAnywhere
- :
- InstallAnywhere Forum
- :
- yes robert i am able to get the value of $JAVA_EXECUTABLE$
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, 2008
03:07 AM
ok if i approach as this where am i going wrong
hi,
now i am using the built in choose jvm panel of installer and after that i add
a custom code action which contains code as this:
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
String javaexecutable=ip.substitute("$JAVA_EXECUTABLE$");
if(javaexecutable.contains("\\Java\\jdk1.5.0_08\\bin\\java.exe")){
ip.setVariable("$GREENFLAG$","1");
}
else{
ip.setVariable("$GREENFLAG$","0");
}
}
And after this custom code action i have added a built in message dialog of installanywhere and on it i added a rule which if returns TRUE then i abort the installation,the code is as :
public boolean evaluateRule() {
// TODO Auto-generated method stub
String todefer=ruleProxy.substitute("$GREENFLAG$");
if(todefer.equals("1")){
return false;
}
else if(todefer.equals("0")){
return false;
}
else
{
return false;
}
}
Can anyone say me where i am going wrong
james
now i am using the built in choose jvm panel of installer and after that i add
a custom code action which contains code as this:
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
String javaexecutable=ip.substitute("$JAVA_EXECUTABLE$");
if(javaexecutable.contains("\\Java\\jdk1.5.0_08\\bin\\java.exe")){
ip.setVariable("$GREENFLAG$","1");
}
else{
ip.setVariable("$GREENFLAG$","0");
}
}
And after this custom code action i have added a built in message dialog of installanywhere and on it i added a rule which if returns TRUE then i abort the installation,the code is as :
public boolean evaluateRule() {
// TODO Auto-generated method stub
String todefer=ruleProxy.substitute("$GREENFLAG$");
if(todefer.equals("1")){
return false;
}
else if(todefer.equals("0")){
return false;
}
else
{
return false;
}
}
Can anyone say me where i am going wrong
james
(2) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2008
05:48 PM
Can your custom code rule read the value of $JAVA_EXECUTABLE$ directly?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 15, 2008
10:55 PM
hi ,
i am able to get the value of $JAVA_EXECUTABLE$ which i am reading and yes my purpose is solved.
james.
i am able to get the value of $JAVA_EXECUTABLE$ which i am reading and yes my purpose is solved.
james.
![](/skins/images/3B39CE851FDD5528C393F146EB70A2D0/responsive_peak/images/icon_anonymous_message.png)