How to Move the Microsoft Access Cursor to the Start of a Field
Question details
The user wants to automatically place the cursor at the beginning of a text control when navigating to it in a Microsoft Access form.

- Product
- Microsoft Access
- Device & OS
- not provided
- Scenario
- Navigating between records or controls within a Microsoft Access form.
- Observed behavior
- The goal is to ensure the insertion point always defaults to the very start (position zero) of a text field when it receives focus, instead of selecting the whole text or jumping to the end.
Ensure you have your Microsoft Access database open in Design View and possess basic familiarity with Visual Basic for Applications (VBA) to edit form events.
Use the GotFocus Event for Text Controls
This is the most flexible and recommended method. It triggers exactly when a specific text control receives focus, avoiding the limitations of hard-coding in the Form_Current event.
By utilizing the GotFocus event, you can apply this behavior to multiple text controls individually. It guarantees that regardless of how the user navigates to the field (via Tab key or mouse click), the cursor will reset to the beginning.
Right-click your form in the navigation pane and select 'Design View'. Click on the text control you want to modify.
Press F4 or click 'Property Sheet' on the Form Design toolbar. Navigate to the 'Event' tab.
Find the 'On Got Focus' property, select '[Event Procedure]' from the dropdown, and click the ellipsis (...) button to open the VBA editor.
Inside the Private Sub procedure, type 'Me.txtFieldName.SelStart = 0' (replacing txtFieldName with the actual name of your control). Save and close the VBA editor.

Use the Form_Current Event for Single Fields
This method forces the cursor to the start of a specific, hard-coded field every time you navigate to a new record in your form.
Looking for a Lightweight and Free Office Suite?
While Microsoft Access is a specialized database tool, most daily office tasks revolve around documents, spreadsheets, and presentations. WPS Office is a free, lightweight, and highly compatible alternative to Microsoft Office that handles all your standard file formats seamlessly.
- 1. Visit the Official Website: Go to the official WPS Office website to download the secure installer.
- 2. Download and Install: Click 'Free Download', run the installation file, and follow the simple on-screen instructions.
- 3. Open Your Documents Natively: Launch WPS Office and immediately start opening, editing, and saving your existing Microsoft Office files without formatting loss.

Frequently Asked Questions
Why does SelStart = 0 not work on Date fields or input masks?
Date fields and controls with input masks have built-in formatting behaviors that can override standard VBA SelStart commands upon receiving focus. To control cursor placement on these fields, you may need to use the MouseUp or Click events instead of GotFocus.
Can I apply this cursor behavior to all text boxes without writing code for each one?
Yes. You can create a Public Function in a standard VBA module that sets 'Screen.ActiveControl.SelStart = 0'. Then, select all your text boxes in Design View, and in the 'On Got Focus' property, type '=YourFunctionName()'. This avoids writing individual subs for dozens of controls.
What does the SelStart property actually do in Microsoft Access VBA?
The SelStart property specifies the starting point of selected text in a control, or the exact position of the insertion point (cursor) if no text is currently selected. Setting it to 0 forces the cursor to the very beginning of the field's content.




