How to make the cursor move to the first pos when you click in a field

8 posts, 0 answers
  1. Jon
    Jon avatar
    539 posts
    Member since:
    Apr 2004

    Posted 12 Nov 2008 Link to this post

    Hi.. I have input control - how can make the cursor go to the first position when a user clicks in the field.
    thanks
  2. Pavel
    Admin
    Pavel avatar
    904 posts

    Posted 13 Nov 2008 Link to this post

    Hi Jon,

    You can use the SelectionOnFocus property of the Input and set it to "CaretToBeginning". More details about this property you can find in this help article.

    Greetings,
    Pavel
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. Jon
    Jon avatar
    539 posts
    Member since:
    Apr 2004

    Posted 13 Nov 2008 Link to this post

    Hi..
    I set the property but it doesn't work - it goes to the position I clicked.
    What's wrong with this ? thanks

     

    <telerik:RadMaskedTextBox ID="txtZIPCODE" Runat="server" Mask="#####-####"

     

     

    Width="75px" TabIndex="11" AutoPostBack="True"

     

     

    SelectionOnFocus="CaretToBeginning"

     

     

    ontextchanged="txtZIPCODE_TextChanged">

     

     

    </telerik:RadMaskedTextBox>

     

  4. Plamen Peshev
    Admin
    Plamen Peshev avatar
    885 posts

    Posted 13 Nov 2008 Link to this post

    Hi Jon,



    I tried to reproduce the described problem by preparing a test project, based on your code, but unfortunately to no avail. Please provide us with your information:
    • What browser do you use and its exact version?
    • What operating system are you running?
    • What version of .NET framework do you use?



    Regards,
    Plamen
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  5. Jon
    Jon avatar
    539 posts
    Member since:
    Apr 2004

    Posted 13 Nov 2008 Link to this post

    ie 7
    .NET 3.5
    Vista Ultimate

    All the control in an ajax panel

    thanks
  6. Plamen Peshev
    Admin
    Plamen Peshev avatar
    885 posts

    Posted 13 Nov 2008 Link to this post

    Hi Jon,


    Unfortunately we are still unable to reproduce the problematic behavior you are experiencing. Can you please check the attached project and let me know if I am missing something?

    Greetings,
    Plamen
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  7. Jon
    Jon avatar
    539 posts
    Member since:
    Apr 2004

    Posted 13 Nov 2008 Link to this post

    Your example behaves the same way!

    You click on the 3rd position and cursor remain at the 3rd postion.

    ???
  8. Plamen Peshev
    Admin
    Plamen Peshev avatar
    885 posts

    Posted 17 Nov 2008 Link to this post

    Hi Jon The Nerd,


    I assume you just use an older version of RadControls for ASP.NET AJAX which causes the problem. Please, give the latest version (Q3 2008) a try and let us know if you need further help.

    Greetings,
    Plamen
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top