Newbie - keeping state and ValidationSummary + RequiredFieldValidator control
Posted on 2006-05-09
I am pretty new to ASP.NET (VS.NET 2003). I have 3 pages (aspx) which act as a survey app. I have to problems
1. I am losing data on controls when I go back a page. Initially I found out that I can't have 2 submit buttons for a form, so next button submits form prev button calls onclick="history.go(-1);. I am assuming it is because of this that I am using data, am I wrong? What can I do to resolve this problem. The Next button(server control) preserves data fine. The Prev button is HTML control
2. I have several RequiredFieldValidators in each form plus 1 ValidationSummary control. I don't know how these work but when I fill a textbox and tab to the next (or click on another control) there is an asterick still displayed for the filled textbox and the validationsummary shows error for the filled textbox. What I would like to achieve is as soon as textbox loses focus do it's validation and if valid don't show any error on the RequiredFieldValidator or ValidationSummary.