How to Reduce Row Spacing in an Access Continuous Form
Question details
The user needs to decrease the vertical space between rows in a Microsoft Access continuous form after changing the text box font size via VBA.

- Product
- Microsoft Access
- Device & OS
- not provided
- Scenario
- Adjusting the continuous form user interface dynamically using VBA to create a tighter display for smaller font sizes.
- Observed behavior
- The text box font size successfully changes via VBA, but the detail row spacing remains too large, leaving excess empty space between the form records.
Ensure you have your Access database open and note the exact height your text boxes need to be to accommodate the new smaller font size.
Adjust Detail Section and Control Height via VBA
Reduce the Height property of the form's Detail section to eliminate excess space, ensuring you first reduce the height of the controls inside it.
In a Microsoft Access continuous form, the space between rows is dictated entirely by the height of the Detail section. However, the Detail section cannot be dynamically or manually made shorter than the tallest control (such as a text box, combo box, or line) contained within it.
To successfully reduce the row spacing, you must first write VBA code to reduce the height of the individual controls, and then reduce the Detail section height to match.
Determine the new height for your text boxes. Access VBA uses 'twips' for measurement instead of inches or pixels (1 inch equals 1440 twips).
In your VBA module, adjust the height of all controls in the Detail section. For example: Me.YourTextBox.Height = 250.
Immediately after adjusting the controls, add code to reduce the Detail section height: Me.Detail.Height = 250. This snaps the row boundary to the newly resized controls.

Looking for a Lightweight Alternative to Microsoft Office?
While Microsoft Access is powerful for complex relational databases, many data tracking and continuous form tasks can be easily managed with a robust spreadsheet. WPS Office provides a lightweight, highly compatible alternative to Microsoft Office suites, completely free of charge.
- 1. Download and install WPS Office: Get the free suite from the official WPS website and complete the quick installation process.
- 2. Launch WPS Spreadsheets: Open the Spreadsheets module, which serves as a highly capable alternative for managing tabular data and lists.
- 3. Import your exported Access data: Seamlessly open CSV or Excel files exported from your database to format and manage your data without complex VBA coding.

Frequently Asked Questions
Why won't my Access Detail section get any shorter in Design View?
The Detail section cannot be made shorter than the tallest control it contains. Check if any text boxes, lines, or hidden controls extend past your desired height limit.
Can I adjust the continuous form row spacing without using VBA?
Yes. Open the continuous form in Design View, click the bottom edge of the Detail section, and drag it upward until it snaps against the bottom of your text boxes.
What measurement unit does Access VBA use for control dimensions?
Microsoft Access VBA uses 'twips' for sizing and positioning properties. There are 1440 twips in a standard inch and 567 twips in a centimeter.




