i am in a situation where i have to achieve bit wired conditional validation server side and client side. the story as follows
a) suppose i have one dropdown
b) two checkboxes,
c) one radio button list
d) one checkbox list
e) few textbox and
f) save button
1) my requirement is when user select one data from dropdown and submit form then validation message will be showing for all controls except two checkboxes.
2) when user select one data from dropdown and select one of the checkboxes out of 2 and submit form then validation message will be showing for all controls except checkbox list.
i know the requirement is bit wired but i have to do similar kind of thing. so please give me suggestion like how to solve it in mvc with custom validation.
how to use ValidationAttribute and IClientValidatable interface
to achieve this validation at client and server side.
thanks