You want to set the focus to the first control on your form that has a validation error.
In the code-behind class for the page, use the .NET language of your choice to:
Write some code that is called from the
focus method of the desired control and sets the
control’s initial focus to itself (see Recipe 3.5 for details).
Add additional code to the Save (or equivalently named) button’s click event handler that searches for a control with a validation error and sets the focus to that control.
RegisterClientScriptBlock method of the
Page object to register the script block so that
it is output when the page is rendered.