« Return to Thread: xforms-value-changed event

xforms-value-changed event

by hcr :: Rate this Message:

Reply to Author | View in Thread

 
 Hi,
   I want to do some action when a node of xforms instance value changed. How can I do it?
   I can use xforms-value-changed to do it, for example:
 
...
<xforms:instance id="data">
     <a>
</xforms:instance>
...
<xforms:input ref="instance('data')/a">
     <xforms:action ev:event="xforms-value-changed">
         <!--to do some thing-->
     </xforms:action>
</xforms:input>
....
   
   but this way have a problem: The xforms-value-changed is dispatched when input control value changed, for example:
...
<xforms:instance id="data">
     <item>
           <a>1</a>
     </item>
     <item>
           <a>2</a>
     </item>
</xforms:instance>
...
<xforms:repeat nodeset="instance('data')/item" id='nav'>
 
<xforms:input ref="instance('data')/item[index('nav')]/a">
     <xforms:action ev:event="xforms-value-changed">
         <!--to do some thing-->
     </xforms:action>
</xforms:input>
 
   when repeat control index change from 1 to 2, will change input control value, so dispatch xforms-value-changed of input control. but node value of xforms instance control is not changed.
 
   Should dispatch event when xforms instance's node value changed? 
 
  
 
 
 
 



22元超值饭面,8.5折纯珍比萨,必胜宅急送网上点餐优惠多

--
You receive this message as a subscriber of the ops-users@... mailing list.
To unsubscribe: mailto:ops-users-unsubscribe@...
For general help: mailto:sympa@...?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws

 « Return to Thread: xforms-value-changed event

LightInTheBox - Buy quality products at wholesale price!