Reputation: 301
I have a page with some linkbuttons and a loginform validates by asp.net validators . when user click in linkbuttons validators prevent postback . linkbuttons are none of loginform business and validtors shouldnt validate when linkbuttons clicked .
What can i do?
tnx in advance...
Upvotes: 1
Views: 2243
Reputation: 47387
You have two parts to work with.
ValidationGroup
CausesValidation=False
Some info on ValidationGroups can be found on Scott Gu's blog
Some info on CausesValidation can be found at 4GuysFromRolla
These can work hand-in-hand or individually to achieve what you're looking for.
Upvotes: 3
Reputation: 12705
set a different group for the validators u dont want to be validated when button is clicked this can be done by "ValidationGroup" property
Upvotes: 3
Reputation: 5986
You can set CausesValidation
property of the LinkButton
to false
, to prevent validation.
Upvotes: 3