Tell me more ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a custom form that is connected to a database. This form is very simple, I have 4 fields, First Name, Last Name, Email and Address. The fields First Name and Last Name are required fields. When I fill out the form and leave one of the required fields blank and click submit I lose the information the user has typed in the textboxes and get the validation error. Is it possible to not lose this information when the user clicks on submit? I am doing this with SharePoint Designer. I would like to avoid using JavaScript, I am pretty sure with SharePoint Designer 2007 the form did not get emptied if there was validation errors.

    <tr>
    <td width="75%" class="ms-vb">
        <asp:TextBox runat="server" id="ff2{$Pos}" __designer:bind="{ddwrt:DataBind('i',concat('ff2',$Pos),'Text','TextChanged','',ddwrt:EscapeDelims(string('')),'@fname')}" />
        <asp:RequiredFieldValidator runat="server" ErrorMessage="RequiredFieldValidator" id="RequiredFieldValidator1" ControlToValidate="ff2_new" />
    </td>
</tr>
<tr>
    <td width="25%" class="ms-vb">
        <b>lname:</b>
    </td>
    <td width="75%" class="ms-vb">
        <asp:TextBox runat="server" id="ff3{$Pos}" __designer:bind="{ddwrt:DataBind('i',concat('ff3',$Pos),'Text','TextChanged','',ddwrt:EscapeDelims(string('')),'@lname')}" />
        <asp:RequiredFieldValidator runat="server" ErrorMessage="RequiredFieldValidator" id="RequiredFieldValidator2" ControlToValidate="ff3_new" />
    </td>
</tr>
<tr>
    <td width="25%" class="ms-vb">
        <b>email:</b>
    </td>
    <td width="75%" class="ms-vb">
        <asp:TextBox runat="server" id="ff4{$Pos}" __designer:bind="{ddwrt:DataBind('i',concat('ff4',$Pos),'Text','TextChanged','',ddwrt:EscapeDelims(string('')),'@email')}" />
    </td>
</tr>
<tr>
    <td width="25%" class="ms-vb">
        <b>address:</b>
    </td>
<td width="75%" class="ms-vb">
    <asp:TextBox runat="server" id="ff5{$Pos}" __designer:bind="{ddwrt:DataBind('i',concat('ff5',$Pos),'Text','TextChanged','',ddwrt:EscapeDelims(string('')),'@address')}" />
</td>
</tr>
share|improve this question

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.