With xforms:repeat i need to keep validations repeatly how ?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

With xforms:repeat i need to keep validations repeatly how ?

Laxmi Narayana-3
Hi All,
 
I have xml nodes like below .Using xforms:repeat I am displaying custom field label(Drop down) and customFieldType(textbox).
On select of drop down like name ,age coresponding data types only will be accepted. other data types selected i need to show
 
error how it is possible in xforms please help me.
 
ex: if i select 'name' corresponding 'string' only will be accepted.
if i select 'age' corresponding 'number 'only will be accepted.
 
 
<customfields>

<customfield id="Character">
<customFieldId>Param1</customFieldId>
<customFieldLabel>Name</customFieldLabel>
<customFieldType>Character</customFieldType>
<customFieldValue>Laxmi</customFieldValue>
</customfield>

<customfield id="Number">
<customFieldId>Param2</customFieldId>
<customFieldLabel>Age</customFieldLabel>
<customFieldType>Number</customFieldType>
<customFieldValue>25</customFieldValue>
</customfield>

<customfield id="Character">
<customFieldId>Param3</customFieldId>
<customFieldLabel>Destination</customFieldLabel>
<customFieldType>Character</customFieldType>
<customFieldValue>Bangalore</customFieldValue>
</customfield>

</customfields>


--
Please help me,  I am new in XForms, It is urgent in my project!
Thanks in advance,
Laxmi Narayana.



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
Reply | Threaded
Open this post in threaded view
|

Re: With xforms:repeat i need to keep validations repeatly how ?

venkata subrahmanyam
Use the following dynamic binds and you can use <xforms:alert>errormessage</xforms:alert> when you have error.


<xforms:bind nodeset="instance('myinstance')/customfields/customfield[customFieldType ='Character']/customFieldValue"  type="xs:string"/>

<xforms:bind nodeset="instance('myinst')/customfields/customfield[customFieldType='Character']/Number" type="xs:int"/>

etc...


Regards
Venkata Subrahmanyam Adapa