P
psparago
I have developed a tab user control in which each tab is itself a user
control and the tab selection control is a datalist.
Each tabbed user control has zero or more validator controls on it. The
hosting page has a summary validator on it.
Each tabbed user control is created dynamically on page_init (on both
postback and not postback), but only the tabbed user control which
corresponds to the selected tab is marked as visible. This has the
effect of only the selected tabbed user control being rendered to the
output page.
Validation works as expected for the selected tabbed user control.
However, when the page is submitted, the summary validator can only
validate the selected tabbed user control (on the client).
What I want to do, is on submit, run through all of the validators on
the page and determine if any of the tabbed user controls that were not
active when the page was submitted have errors.
(A secondary desire is to be able to do a summary validation on the
page that is being deselected when a different tab is selected, but
I'll save that for another time.)
In my event handler for the submit button, I iterate through the
Validators collection and call Validate() on each IValidator object.
Even though one of the tabbed user controls have an error, that
validator (a RequiredValidator) says it is valid.
Does this ring any bells with anyone?
thanks
peter
control and the tab selection control is a datalist.
Each tabbed user control has zero or more validator controls on it. The
hosting page has a summary validator on it.
Each tabbed user control is created dynamically on page_init (on both
postback and not postback), but only the tabbed user control which
corresponds to the selected tab is marked as visible. This has the
effect of only the selected tabbed user control being rendered to the
output page.
Validation works as expected for the selected tabbed user control.
However, when the page is submitted, the summary validator can only
validate the selected tabbed user control (on the client).
What I want to do, is on submit, run through all of the validators on
the page and determine if any of the tabbed user controls that were not
active when the page was submitted have errors.
(A secondary desire is to be able to do a summary validation on the
page that is being deselected when a different tab is selected, but
I'll save that for another time.)
In my event handler for the submit button, I iterate through the
Validators collection and call Validate() on each IValidator object.
Even though one of the tabbed user controls have an error, that
validator (a RequiredValidator) says it is valid.
Does this ring any bells with anyone?
thanks
peter