Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Help   Contact   Merch   Join   Order   Logon   Forums   
 
Back to Visitor Forum    Comments List
Upload Images   @Reply   Bookmark    Link   Email   Next Unseen 
Access SharePoint Mail Merge
David OldenKamp 

16 months ago
Thanks for you instructional videos! I've split my DB with Sharepoint lists as the backend and each user having a separate Access front end. We use Word Templates and Mail Merge to send form letters. If Access is open and we try run a Merge, we get the error, "The database has been placed in a state by user 'Admin' on machine 'xxxxx' that prevents it from being opened or locked." Closing the DB on that machine allows the Mail Merge to connect. I've tried using the "Word Merge" button from inside Access and receive the same error. I've opened 2 different merge letters with the DB closed, and they connected. Then I opened the DB and received a different error: "The database 'xxxxxx' cannot be opened in exclusive mode because it contains links in a cached mode." I change the Options > Current Database > Caching Web Service and Sharepoint Tables > Never Cache, but it didn't' seem to make a difference. Does anybody use Mail Merge through Access with SP as the backend?
Richard Rost  @Reply  
          
16 months ago
I've never run into this problem myself, but then again I haven't tried it. I use SharePoint very sparingly. I prefer SQL Server. But I asked your question at ChatGPT, and here's what it gave me:

You're encountering a well-known and frustrating issue when trying to use Microsoft Word Mail Merge with an Access front end that links to SharePoint lists.

Here's what's going on:

The Problem

Word Mail Merge, when using an Access database as the data source, tries to open the database in exclusive mode. If another user (or yourself) already has the front end open, Word can't grab exclusive access, which triggers the error:

"The database has been placed in a state by user 'Admin' on machine 'xxxxx' that prevents it from being opened or locked."

With a SharePoint backend, the situation gets worse because of SharePoint's use of Web Services and caching, which can confuse Access and Word when dealing with simultaneous connections.

Changing the caching option (`Never cache`) is a good step, but unfortunately, it doesn't stop Word from trying to open the Access database in exclusive mode, which is the core problem.

---

Workarounds and Solutions


Here are some practical ways you might work around this:

1. Use Excel as an intermediate data source
   - Instead of having Word connect directly to Access, export the data from your Access query into Excel (e.g., `TransferSpreadsheet`) and then use that Excel file as the Mail Merge data source.
   - This completely sidesteps the exclusive lock issue because Excel can be read freely by multiple processes.

2. Automate the Mail Merge from Access
   - Create a Mail Merge automation directly in Access using VBA. This way, Access opens Word and feeds it data.
   - But note: if you do this from within Access, you still might get locking problems if the same database is trying to connect to itself for merge data. To fix that, use a local exported copy (see point #1).

3. Use temporary local tables or files
   - For each user, when it's time to generate a letter, have Access export the required data to a local table, or even to a CSV or Excel file, and then run the Mail Merge against that.

4. Avoid linked SharePoint lists in Mail Merge
   - SharePoint-linked tables often behave unpredictably due to the extra layers of abstraction. If possible, export a snapshot of the data you need to a local Access table or Excel before merging.

5. Try setting the merge letter to use an external file (CSV or Excel)
   - If you must use Word manually, set the data source to a CSV or Excel file created from Access ahead of time. That way the file is stand-alone and not linked to a live Access database.

---

Summary


No, you are not alone. Many Access developers using SharePoint as a backend run into these exclusive lock issues with Word Mail Merge. The most reliable solution is:

Export your merge data to a local Excel or CSV file first, then use Word to connect to that file instead of the live Access DB.

If you want help building a Mail Merge export feature or automating Word from VBA, let me know and I can give you a sample.

Would you like a quick sample routine for exporting to Excel and launching a Word merge from Access VBA?
Richard Rost  @Reply  
          
16 months ago
Head over to ChatGPT, and it might be able to give you some step-by-step instructions on how to get around that problem.
David OldenKamp OP  @Reply  

16 months ago
Thanks for the quick response, Richard! ChatPT sure explains it. I too would prefer to switch to SQL Server, but Sharepoint is included with our MS license, and the Azure Database Model for our small business is a nightmare. I'd like to see some quick code on exporting to Excel and opening Word merge from VBA. That might be the solution until we move to SQL. Thanks!
Richard Rost  @Reply  
          
16 months ago
I do cover exporting to Excel in my Access lessons. As far as opening a word merge from VBA, you can just write the documents directly in Access, create reports out of them, that's what I do. But I am going to be making some more videos on integrating Access and Word mail merge with VBA soon.

As far as moving to SQL SQL Server Online goes, I would recommend switching to WinHost. They're very inexpensive, less than $10 a month, and you get website hosting whether you need it or not, and SQL Server hosting.
Sami Shamma  @Reply  
             
16 months ago
Let me give a shout out to Winhost.
We migrated one of my servers from a shared server to a dedicated server. The backup and restore did not work due to differences in the SQL server versions. They worked with us over Sunday and made sure that we were up and running so our customer could continue working without interruption on Monday morning. They have absolutely amazing service.
Richard Rost  @Reply  
          
16 months ago
Yeah, they made my transitions seamless twice. I migrated over from GoDaddy (my last disaster of an ISP) to WinHost several years ago. And then last year I upgraded from their shared hosting to my own dedicated server, and again their guys took care of everything; it was seamless. I had some issues afterwards - just stuff on my end that I needed help with (like specific server configurations that I need), and they took care of me within minutes. Their tech support is not only responsive but fast, and they don't make you call and sit on hold for support. You can email them, which I love doing, especially for things that aren't critical.

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Visitor Forum.
 

Next Unseen

 
New Feature: Comment Live View
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 8/1/2026 4:07:10 AM. PLT: 1s