-
FEATURED COMPONENTS
First time here? Check out the FAQ!
After compilation this Doc-Page my HelloZK looks like:
<window id="win" border="normal" width="600px" xmlns:w="http://www.zkoss.org/2005/zk/client"> <textbox id="textToEval" value ="1+2" onChanging="resultLabel.value=event.value"/> <label value=" Hello ZKalkulator! Just try to edit expression in the text field to get result..." id="resultLabel"> <attribute w:name="setValue"> function (value) { this.$setValue(value); //call the original method if (this.desktop) { this._flag = !this._flag; this.setStyle('background:'+(this._flag ? 'red':'green')); this.$setValue( eval ( ''+value+'') ) ; } } </attribute> </label> </window>
So, its works (WONDERFULL even on ONLINE_DEMO!) as good as should...
.. till expr-eval-error. How can i process wrong expression-evaluation otherwise?
please don't cross post
Asked: 2010-08-24 14:29:25 +0800
Seen: 330 times
Last updated: Aug 24 '10