Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Compact Database in Access 2007 receives 3251 Error

Status
Not open for further replies.

ISUTri

MIS
Mar 25, 2004
38
US
We are currently converting from Access 2003 to Access 2007. I have
an Access app that is going to be very difficult to convert. This App
is used by people that are out in the field and are a long distance
from where our Access Databases are. So that is why we have
Replication set up. So they have a local copy that they can replicate
to our copies when they are in a high speed area. Since they have
data on their local laptop we use VBA code to compact these
databases. This code is

DBEngine.CompactDatabase "C:\Source.mdb", "c:\SourceTmp.mdb"


The error I receive is:
Error 3251
Operation is not supported for this type of object.
Position = 2


Any help would be appreciated.


Thanks,
Jon
 
A couple of things:

1. If you are using Replication, this had better be a split frontend/backend database with the BACKEND ONLY replicated.

2. Replication is NOT INTENDED for items such as forms, reports, code, etc. It is ONLY intended for TABLES.

And just so you know - if you use replication on a non-split database you greatly increase the odds that you will have a catastrophic corruption sometime. It may not have happened yet, but you can bet that it will at some point.

Anyway, this may be one of those meltdowns.


Bob Larson
A2K,A2K3,A2K7,SQL Server 2000/2005,Crystal Reports 10/XI,VB6, WinXP, and Vista
Free Quick Tutorials and Samples:
 
sorry for the long wait between responses but here it goes.

1) This is a split database. There is a front end and a back end. The users have laptops that have a front end on their laptop along with a backend. As they work the data gets populated in their backend. When they get to a hotspot they "sync" or "replicate" with the main table that is located on our server.

2) I am only replicating tables. This app has actually been working for a very long time (over 7 years) through various access upgrades. This app was created back when everyone dialed up and no one had broadband.

The Sync worked for a second when I fixed the compact issue. But now the Sync no longer works and is giving me hte 3251 error again.
 
I forgot to paste my Replication Code. I am using Access 2007 with a Access 2003 MDB.
Set db = DBEngine(0).OpenDatabase("C:\Snapshot\LocalReplica.mdb")

strSyncTargetDB = "\\server\ServerReplica.mdb"

db.Synchronize strSyncTargetDB, dbRepImpExpChanges
db.Close

My references are still DAO 3.6 Object Library and it is promoted as high as it will go.

Thanks for any help!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top