>>>Hi everybody,
>>>
>>>I tried to just set a DefaultFocus property of the page to the name of my control (inside the LoginView) but it doesn't work.
>>>
>>>Here is the link I found
http://www.beansoftware.com/ASP.NET-Tutorials/Focus-ASP.NET.aspx>>
>>There are three different suggestions there. Which did you try?
>>
>The simplest of setting DefaultFocus property for the form. My next take would be to try JavaScript code, but I hoped the DefaultFocus would be enough.
Setting DefaultFocus in the markup works for me. Also
Page.Form.DefaultFocus = "textbox";
Page.Form.DefaultFocus = textbox.ClientId;
in the Page load has the same effect. In either case the following javascript is generated in the form tag of the HTML:
<script type="text/javascript">
WebForm_AutoFocus('textbox');//]]>
</script>