Others

Fix Access Runtime Error 3709 When Clearing a Subform Filter

Olivia MillerOlivia Miller Oct 22, 2026 869 views

Question details

The user needs to resolve an issue where clearing or reapplying a filter on a subform triggers a runtime error.

How to Fix Access Runtime Error 3709 When Clearing a Subform Filter
Product
Microsoft Access
Device & OS
not provided
Scenario
Using VBA code to clear or reapply a filter on an Access subform by setting the filter text to an empty string.
Observed behavior
Microsoft Access throws Runtime Error 3709 ('The search key was not found in any record') when the filter is cleared while the FilterOn property remains enabled.
Before you start

Before modifying your VBA code, make sure to back up your Access database and identify the specific form and event where the subform filter is being triggered.

Solution 1Recommended

Disable the Subform Filter Using the FilterOn Property

The most effective way to clear a filter without triggering an error is to turn off the filter entirely rather than setting the filter string to an empty value.

Setting a filter to an empty string ("") while the FilterOn property remains set to True confuses the Access database engine. To safely remove the filter from a subform, you must instruct Access to stop applying the filter altogether.

1
Open the VBA Editor

Open your Microsoft Access database, navigate to the form causing the issue, and switch to Design View. Press Alt + F11 to open the VBA Editor.

2
Locate the Filter Clearing Code

Find the line of code that attempts to clear the filter. It usually looks something like: Me.SubformName.Form.Filter = ""

3
Replace the Filter String

Delete or comment out that line, and replace it with code that toggles the filter off: Me.SubformName.Form.FilterOn = False

4
Save and Test

Save your VBA project, close the editor, and switch your form back to Form View to verify that clearing the subform filter no longer triggers Error 3709.

Disable the Subform Filter Using the FilterOn Property
Best Practice: Always manage the FilterOn property explicitly when building dynamic search forms or conditional filters in Access.
Free Microsoft Office alternative

Looking for a Lightweight Microsoft Office Alternative?

While Microsoft Access handles complex database management, many users simply need a fast, reliable, and cost-effective suite for their daily Word, Excel, and PowerPoint tasks. WPS Office offers an intuitive, tabbed interface and complete compatibility with standard Office files without the heavy resource usage.

  1. 1. Download the Installer: Visit the WPS Office website and click on 'Download WPS Office Free' to get the installer for your operating system.
  2. 2. Install the Suite: Run the downloaded file and follow the on-screen prompts to quickly install WPS Office on your computer.
  3. 3. Open Your Office Files: Launch WPS Office and open your existing .docx, .xlsx, or .pptx files to continue working immediately.
Seamlessly compatible with Microsoft Word, Excel, and PowerPoint formatsLightweight design that runs quickly on older or low-spec devicesFree to use with a familiar, easy-to-navigate tabbed interfaceBuilt-in PDF reader, editor, and conversion tools included
microsoft office alternative - wps office

Frequently Asked Questions

Why does setting an Access filter to an empty string cause Runtime Error 3709?

When the FilterOn property is set to True, Access expects a valid SQL WHERE clause string in the Filter property. Passing an empty string confuses the database engine, causing it to fail when attempting to find records matching a blank or non-existent key.

Should I just use an 'On Error Resume Next' statement to ignore this error?

It is not recommended. Suppressing the error with 'On Error Resume Next' might hide underlying issues with your data or syntax. It is always better to fix the root cause by toggling the FilterOn property to False.

Does this fix apply to main forms as well as subforms?

Yes. While the error is frequently encountered on subforms, setting the FilterOn property to False instead of clearing the filter text is the standard best practice for managing filters on both main forms and subforms in Microsoft Access.