Hollis, Virginia
hollisvj at pgdp.usec.com
Fri Sep 29 07:57:24 CDT 2006
No, wish it was that easy..... that is already selected. When they click or enter the combo box, it does not select the existing text. Shouldn't the SelLength or one of the Sel do it? But it isn't.... Virginia ________________________________ ...tools/options/keyboard/select entire field? William Hindman ________________________________ From: Hollis, Virginia Sent: Thursday, September 28, 2006 2:13 PM To: 'accessD at databaseadvisors.com' Subject: Select All Text in DropDown I have a form with a combo box that brings up the data for the selected name in the dropdown. When the user enters, clicks, or has the focus of the combo I need it to select all the text in the field. For some reason it always goes to the beginning of the field so they can't just start typing a name to find it, they always have to scroll the list or highlight the text in the box first, then delete it or start typing after it is highlighted. They want the text in the combo from the current record to already be highlighted so they can easily find another record by typing the person's name without any extra steps. I tried this, but it only highlights the first 3 characters of the name instead of the whole name. How does it determine the length of the field and select all of it? Private Sub FindName_GotFocus() FindName.SetFocus FindName.SelLength = Len(FindName) End Sub Virginia