Hi,
I have a bit of script that I am using to set focus back onto a textbox but when I use it, the cursor is always at the beginning of the text but I need it to be at the end. Does anyone know how to do this?

Code:
        Dim strBuilder As String
        strBuilder = "<script language = 'javascript'>"
        strBuilder = strBuilder & "document.forms.Form1.txtSearch.focus();"
        strBuilder = strBuilder & "</script>"
        RegisterStartupScript("Focus", strBuilder.ToString)
That's my code to set the focus back on the text box. Any help in ASP.NET or Javascript will be v.helpful.

Thanks in advance!!