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: trouble with persistent variables
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
‎Dec 13, 2006
01:19 PM
trouble with persistent variables
If I use a persistent local variable in the Process Exit Code Variable field of an Execute Process, why isn't the return code shown in the Property Manager?
(5) Replies
‎Dec 13, 2006
04:25 PM
Hugn! What you mean ming!
I think your missing the meaning of persistant variables. This would be a variable that you can store in the VPD to read on re-install, un-install or even patch of the product!
I believe what is in the Property Manager is just the default value of the Variable!
Hope this helps!
Regards,
Tom
I think your missing the meaning of persistant variables. This would be a variable that you can store in the VPD to read on re-install, un-install or even patch of the product!
I believe what is in the Property Manager is just the default value of the Variable!
Hope this helps!
Regards,
Tom
‎Dec 14, 2006
09:19 AM
So how can I display the return code of a variable instantiated in the Process Exit Code Variable field?
‎Dec 14, 2006
01:26 PM
Acdording to the help you should just be able to get the value with $V(RETURN_CODE)!!!
Although: I have a call into support because it does not seem to be working!
What I have tried is a simple test with 2 dialogs that have a textbox on it and I use a variable RETURN_CODE with an initial value of 'XXXX' for both dialogs. I then added them to my sequences and added an Execute process in between them using RETURN_CODE for the variable!
For my command of the EP I just used a basic unix cmd 'pwd' - when I run this on Unix, the first dialog shows XXX then it runs the command and the next dialog shows 0. But when I run on Windows it showes the same thing, 0, I would think it should be non-zero but it is not!!!!
So I changed the command to 'asdf' and got the same results on Unix and Windows! I even added a Custom Event to look at the $V(RETURN_CODE) and got the same results!
Ug!
Although: I have a call into support because it does not seem to be working!
What I have tried is a simple test with 2 dialogs that have a textbox on it and I use a variable RETURN_CODE with an initial value of 'XXXX' for both dialogs. I then added them to my sequences and added an Execute process in between them using RETURN_CODE for the variable!
For my command of the EP I just used a basic unix cmd 'pwd' - when I run this on Unix, the first dialog shows XXX then it runs the command and the next dialog shows 0. But when I run on Windows it showes the same thing, 0, I would think it should be non-zero but it is not!!!!
So I changed the command to 'asdf' and got the same results on Unix and Windows! I even added a Custom Event to look at the $V(RETURN_CODE) and got the same results!
Ug!
‎Dec 18, 2006
03:19 PM
Could you share your code to print out the return code that displays the XXX and the 0?
‎Dec 19, 2006
09:39 AM
First off - in trying this on my own it doesn't seem to be working! I do have an incident in with InstallShield Support and waiting to hear from them!
But, as a simple test, you can see if you get the same results I am because the return code for me anyway always returns a 0, even when I use an invalid command!
Create a new blank dialog box and just add a textbox on it and use RETURN_CODE for the variable and give it an initial value of XXXX.
Add this to the sequence and add the Execute process after it and use the same variable, RETURN_CODE, for the Process Exit whatever variable!
Add the same dialog after the EP and run and you should see the two different results!
Or - you can add a Custom Event after the Execute process and just get the variable by:
String rc = arg0.resolveString("$V(RETURN_CODE)");
JOptionPane.showMessageDialog(null,"Return code = " + rc);
Regards,
Tom
But, as a simple test, you can see if you get the same results I am because the return code for me anyway always returns a 0, even when I use an invalid command!
Create a new blank dialog box and just add a textbox on it and use RETURN_CODE for the variable and give it an initial value of XXXX.
Add this to the sequence and add the Execute process after it and use the same variable, RETURN_CODE, for the Process Exit whatever variable!
Add the same dialog after the EP and run and you should see the two different results!
Or - you can add a Custom Event after the Execute process and just get the variable by:
String rc = arg0.resolveString("$V(RETURN_CODE)");
JOptionPane.showMessageDialog(null,"Return code = " + rc);
Regards,
Tom