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: Could not update value in the Custom Dialog Input Box
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
Sep 11, 2006
07:49 AM
Could not update value in the Custom Dialog Input Box
Hi,
Here is my scenario. I have one custom dialogue in which I have one input box. There I added a new varaible "CR_VERSION" for the input box.
I want to set default value to this input box. Hence I added a event "QueryEnter" for this custom dialogue. Here is my code
public void queryEnterRequestVersion(com.installshield.event.ISQueryContext arg0)
{
String CRVersion;
try {
CRVersion = execute();
arg0.getServices().getISDatabase().setVariableValue(
"CR_VERSION","V34BTest");
arg0.getServices().getISDatabase().setVariableValue(
"RETURN_VAL", "true");
}
catch (ISDatabaseException dbe){
} catch(ServiceException e){
LogUtils.getLog().logEvent(this, Log.ERROR, e);
}
}
But It does not update the value which I'm passing thru the code. Please guide me where I'm doing mistake.
Thanks
Subramanian S
Here is my scenario. I have one custom dialogue in which I have one input box. There I added a new varaible "CR_VERSION" for the input box.
I want to set default value to this input box. Hence I added a event "QueryEnter" for this custom dialogue. Here is my code
public void queryEnterRequestVersion(com.installshield.event.ISQueryContext arg0)
{
String CRVersion;
try {
CRVersion = execute();
arg0.getServices().getISDatabase().setVariableValue(
"CR_VERSION","V34BTest");
arg0.getServices().getISDatabase().setVariableValue(
"RETURN_VAL", "true");
}
catch (ISDatabaseException dbe){
} catch(ServiceException e){
LogUtils.getLog().logEvent(this, Log.ERROR, e);
}
}
But It does not update the value which I'm passing thru the code. Please guide me where I'm doing mistake.
Thanks
Subramanian S
(1) Reply
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Sep 11, 2006
01:09 PM
It looks OK, just not sure what these statements are doing:
String CRVersion;
CRVersion = execute();
But this is all you would need to do:
arg0.getServices().getISDatabase().setVariableValue("CR_VERSION","V34BTest");
But you may want to do it in the Dialogs initializeUI event or put it in the Events Class in the OnBegin Install and set all your defaults there! That way you have one method if you want to change anything!
Better yet - I would use the 'Additional Tools' ->'Property Manager' to set a default value to a variable.
String CRVersion;
CRVersion = execute();
But this is all you would need to do:
arg0.getServices().getISDatabase().setVariableValue("CR_VERSION","V34BTest");
But you may want to do it in the Dialogs initializeUI event or put it in the Events Class in the OnBegin Install and set all your defaults there! That way you have one method if you want to change anything!
Better yet - I would use the 'Additional Tools' ->'Property Manager' to set a default value to a variable.