Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

How to specify validation for a field on a form and how to specify a validation error page for a form in SharePoint Designer 2007 and in FrontPage 2003


View products that this article applies to.

Introduction

This article describes how to specify validation for a field on a form and how to specify a validation error page for a form in Microsoft Office SharePoint Designer 2007 and in Microsoft Office FrontPage 2003.

Note The examples in this article describe how to validate a Textbox�field. However, you can follow these steps for other kinds of fields on a form.

↑ Back to the top


More information

How to specify validation for a field on a form in SharePoint Designer 2007

To specify validation for a field on a form, follow these steps:
  1. Open your website.
  2. In Design�view, click to add a cursor into the page.
  3. In the Toolbox task pane, right-click Input (Text) under Form Controls, and then click Insert.
  4. Right-click the text box, and then click Form Field Properties.
  5. In the Text Box Properties dialog box, click Validate.
  6. In the Text Box Validation�dialog box, select the kinds of validation that you want. To require the user to enter data for the field, select the�Required check box under Data length.
  7. Click OK to close the Text Box Validation dialog box.
  8. Click OK to close the Text Box Properties dialog box.

How to specify a validation error page for a form in SharePoint Designer 2007

Validation is performed by JavaScript on the client computer. If JavaScript is turned off in the web browser, the URL that is specified in the following steps is displayed.

To specify a validation error page for a form, follow these steps:
  1. Open your website.
  2. Open the webpage that contains your form.
  3. Right-click the form, and then click Form Properties.
  4. In the Form Properties dialog box, click Options.
  5. Click the Confirmation Page tab.
  6. In the URL of validation failure page (optional) text box, type the URL to the validation error page that you want to be displayed.

    Note�This step assumes that you have already created the validation error page that you want to be displayed. If you do not specify a URL in this step, SharePoint Designer 2007 displays a default error page.
  7. Click OK to close the Saving Results dialog box.
  8. Click OK to close the Form Properties dialog box.

How to specify validation for a field on a form in FrontPage 2003

To specify validation for a field on a form, follow these steps:
  1. Open your website.
  2. On the File menu, click New.
  3. On the New task pane, click Blank page.
  4. On the Insert menu, point to Form, and then click Textbox.
  5. Right-click the text box, and then click Form Field Properties.
  6. In the Text Box Properties dialog box, click Validate.
  7. In the Text Box Validation�dialog box, select the kinds of validation that you want. To require the user to enter data for the field, select the�Required check box under Data length.
  8. Click OK to close the Text Box Validation dialog box.
  9. Click OK to close the Text Box Properties dialog box.

How to specify a validation error page for a form in FrontPage 2003

Validation is performed by JavaScript on the client computer. If JavaScript is turned off in the web browser, the URL that is specified in the following steps is displayed.

To specify a validation error page for a form, follow these steps:
  1. Open your website.
  2. Open the webpage that contains your form.
  3. Right-click the form, and then click Form Properties.
  4. In the Form Properties dialog box, click Options.
  5. Click the Confirmation Page tab.
  6. In the URL of validation failure page (optional) text box, type the URL to the validation error page that you want to be displayed.

    Note This step assumes that you have already created the validation error page that you want to be displayed. If you do not specify a URL in this step, FrontPage 2003 displays a default error page.
  7. Click OK to close the Saving Results dialog box.
  8. Click OK to close the Form Properties dialog box.

↑ Back to the top


Keywords: KB891816, kbhowto, kbforms

↑ Back to the top

Article Info
Article ID : 891816
Revision : 4
Created on : 9/13/2011
Published on : 9/13/2011
Exists online : False
Views : 413