Fix Microsoft Access Not Launching from Batch File on Windows Server
Question details
An Access 2013 ACCDB database fails to execute from a batch script on Windows Server, failing silently without opening the command prompt or writing to the log.

- Product
- Microsoft Access
- Device & OS
- Windows Server
- Scenario
- A user is trying to run an automated batch file to launch an Access utility from a mapped network drive, but it fails silently unless manually triggered.
- Observed behavior
- The batch file does not launch the database or log any errors. Launching the database manually temporarily restores the batch file's functionality.
Verify that your mapped network drive is actively connected and that your Windows Server user profile has the correct read and write permissions for the directory containing the database.
Add the Network Drive to Access Trusted Locations
Microsoft Access security settings block databases and macros located in untrusted network folders, which causes automated batch executions to fail silently. Adding the path to Trusted Locations resolves this.
By default, Office applications apply strict security policies to files hosted on network drives to prevent malicious scripts from executing. To allow a batch file to trigger an Access database over the network securely, the host folder must be explicitly trusted.
Launch Microsoft Access manually, click on the 'File' tab in the top-left corner, and select 'Options' at the bottom of the menu.
In the Access Options window, click on 'Trust Center' on the left sidebar, then click the 'Trust Center Settings' button on the right.
Select 'Trusted Locations' from the left menu. At the bottom of the pane, check the box labeled 'Allow Trusted Locations on my network (not recommended)'.
Click the 'Add new location' button. Browse to the network folder containing your database (e.g., Q:\NJ), check 'Subfolders of this location are also trusted', and click 'OK'.

Verify Mapped Drive Availability and Batch File Path
Ensure the batch script is using the absolute executable path for Microsoft Access and that the network drive mounts successfully before the script executes.
Discover a Seamless, Lightweight Alternative to Microsoft Office
While WPS Office does not feature a direct clone of Microsoft Access database software, it is a highly capable and entirely free alternative for managing all your text documents, spreadsheets, and presentations. It runs smoothly on Windows, offering excellent performance and deep compatibility with standard Office files.
- 1. Download the Installer: Visit the official WPS Office website and click the 'Download' button to get the latest free version.
- 2. Install on Windows: Run the downloaded executable file, agree to the terms, and click 'Install'. The lightweight installation takes only minutes.
- 3. Open Your Files Seamlessly: Launch WPS Office and directly open any existing Microsoft Word, Excel, or PowerPoint files without losing your formatting.

Frequently Asked Questions
Why does my batch file run perfectly when I execute it manually but fail on an automated schedule?
Automated scripts (like those run by Task Scheduler) often run under a different system context or security permission level than your active user account. If the network drive isn't mapped for that background context, or Access Trust Center policies block automated executions from unverified locations, it will fail silently.
Can I run a specific Access macro from a Windows batch file?
Yes. You can append the `/x` switch followed by the name of the macro in your batch file. The syntax is: "C:\Path\To\MSACCESS.EXE" "C:\Path\To\Database.accdb" /x MacroName
Why is the 'Add new location' button greyed out in the Trust Center?
This happens when your organization manages Office security policies via Group Policy Objects (GPO). In these managed environments, local users are restricted from adding untrusted network paths, and you must request your IT department to whitelist the directory.




