[izpack-devel] Variables defined in UserInputPanel vs silent mode

Piotr Skowronek piotr at skowro.net
Fri Jan 18 12:30:37 CET 2008


Hi Dennis,

Thanks for the hint how to debug variables and conditions this way!
It is much better than using DataCheckPanel!

But, I've checked the state of conditions, and it looks like they work
properly. When the first condition is met, the second one seems to
destroy the variable. I'm not sure what is going on there, I haven't
debut it, yet (i have no time in the moment).

Let me tell you what I have done. I have conditions defined in seperate
file, where i have:
<condition>
	<condition type="packselection" id="isXpack">
		<packid>X</packid>
	</condition>
</condition>

and install.xml has:

<dynamicvariables>
	<variable name="test" value="test1" condition="isXpack"/>
	<variable name="test" value="test2" condition="!isXpack"/>
</dynamicvariables>

And, if X pack is selected for the installation, then _no_ test variable
appears at all. But, when X pack is deselected, then test variable
is set and contains test2. So it appears, that when the next condition
is not met, the variable is killed...

Thanks in advance
Piotr Skowronek


Dennis Reil pisze:
> Hmm, if mycondition1 is true, app-version should have a value of 1.4.
> 
> Look at http://blog.reil-online.de/2007/12/how-to-debug-variables-and-conditions.html on how to debug condition and variable changes.
> 
> Regards,
>    Dennis
> 
> -----Ursprüngliche Nachricht-----
> Von: izpack-devel-bounces at lists.berlios.de [mailto:izpack-devel-bounces at lists.berlios.de] Im Auftrag von Piotr Skowronek
> Gesendet: Freitag, 18. Januar 2008 10:09
> An: izpack-devel at lists.berlios.de
> Betreff: Re: [izpack-devel] Variables defined in UserInputPanel vs silent mode
> 
> Dennis Reil pisze:
>> Hi,
>>
>> The dynamic variables should be used as replacement for variables only defined in UserInputPanel as they are more general and with variables in UserInputPanel you could have problems if changing the panel order in the future.
> 
> Hi Dennis,
> 
> I was trying to use dynamic variables, but had problems with using 
> Conditions with them. The example in docs looks like:
> <dynamicvariables>
>        <variable name="app-version" value="1.4" condition="mycondition1"
>        <variable name="app-version" value="1.4b" 
> condition="!mycondition1" />
>        <variable name="released-on" value="08/03/2002" />
> </dynamicvariables>
> 
> 
> But, it seems that app-version variable is destroyed when
> mycondition1 is true. It looks like, that second condition removes
> previous declaration of app-version. Did you experience such problem?
> 
> Regards
> Piotr Skowronek
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel
> _______________________________________________
> izpack-devel mailing list
> izpack-devel at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/izpack-devel
> 
> 



More information about the izpack-devel mailing list