Adding Validation Controls

When you're creating mobile Web pages, you're likely to want to validate user input before submitting it to the server. The Microsoft Mobile Internet Toolkit provides the same set of validation controls you'll find in standard ASP.NET pages.

NOTE

Unlike standard ASP.NET validation controls, the Microsoft Mobile Internet Toolkit's validation controls perform no client-side validation. All validation for these controls takes place on the server.

On the first form, you might want to require that the user supply a password before retrieving other information. You can use the RequiredFieldValidator control to accomplish this. Follow these steps to add this control to your page:

1.
Select frmMain.
2.
Click txtPassword ...

Get ASP.NET Developer's JumpStart now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.