Please help me out in doing validation for the following scenario using Validation.xml
I have a drop down With 3 state values(ex: Kentucky,Michigan) and
a textbox which will accept the claim# for the state selected.
conditions.
1. Both state dropdown and claim# can be null.
2. A value is selected from State dropdown but no values can be entered for claim#.
3. Claim# format for each of the state selected are different(for ex Kentucky takes a
String of length 8 or 9, MI takes a String of length 5).
I tried both requiredif and validWhen constructs in validation.xml but its not satisfying all sceanrios.
Please help me out with the validation.