Re: Selecting All Text in TextBox



DRKML wrote:
> When I open a form I want to have the all of the text in the first
> control selected. If I SetFocus the cursor is at the end of the text.
>
> How can I have all of the text selected?

Hi,

Take a look at the SelStart and SelLength properties of the textbox object.

Rob


.



Relevant Pages

  • Setfocus question
    ... On a form, when field A is changed, I update field B automatically by ... Setfocus to field B, and then assign it with another value. ... Tony ... Prev by Date: ...
    (microsoft.public.access.formscoding)
  • Setfocus question
    ... On a form, when field A is changed, I update field B automatically by ... Setfocus to field B, and then assign it with another value. ... Tony ... Prev by Date: ...
    (comp.databases.ms-access)
  • Outlook Custom Form - SetFocus()
    ... Does anybody know of a workaround that allows the SetFocus() method to work ... from the Item_CustomPropertyChange event on an Outlook Custom Form? ... Prev by Date: ...
    (microsoft.public.outlook.program_forms)
  • Is this possible??
    ... May I control the object in OS, such as switching between window, setfocus ... Prev by Date: ...
    (microsoft.public.scripting.vbscript)