Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1185
Setting Focus() to dropdown server side
posted

I have a form including a WebDropDown control which is otherwise working fine. I recently changed the default Focus() fo rthe form to be the drodown control, and it seem sot misbehave in this circumstance.

When focus is set by default, the caret is at the END of the default text inth e control, which means that NO KEYBOARD selection is possible untilt heuser either tabs out an then back in (which selects all the text in the control), or uses the mouse to drop down the list.

On occasion (in IE) the whole contol seems unresponsive, but I haven't isolated whether that is a localised issue or something else.

This ONLY occurs when the control has the default focus for a form. Tabbing in and out of a dropdown that is part of a larger data entry set works fine.

This seems similar to other issues reported here, but with a different cause. Is this a bug or what?

Parents
  • 24671
    Verified Answer
    posted

    Hi,

    Thank you for your feedback. About the unresponsiveness under IE, I am not sure what could be the cause without looking at some isolated code that reproduces this issue. It could be actually many things, but it could be related to number of dropdowns on the form and number of items on them. If you can suggest these numbers to me, i can try to help with some performance improvements. 

    About the caret at the end of the text when there is default focus, I don't know how you are setting the initial focus in the control, but  I can suggest a workaround using the Initialize/Focus client-side event:

    sender._elements["Input"].select();

     

    This will make sure that the whole text is selected, so that the end user can start typing directly without doing any other actions.

     

    Hope it helps,

    Angel 

Reply Children
No Data