470,561 Members | 1,909 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,561 developers. It's quick & easy.

Access 2003 corruption: is this one salvageable?

DFS
"[database name] has detected corruption in this file. To try to repair the
corruption, first make a backup copy of the file. Then, on the Tools menu,
point to Database Utilities and click Compact and Repair database. If you
are currently trying to repair this corruption then you will need to
recreate this file or restore it from a previous backup."

I think it's my usage of the Excel 9.0 object library that's causing the
problem, but I can't be sure.

It's a corruption in one or all of the modules. None will open.

I can put forms in design mode, but can't add objects to them. I can
sometimes open tables.

None of the usual repair / recovery methods works:
* Compact and Repair
* create new db and import objects
* delete non-corrupt module, Compact and Repair
* export modules to another file

Any ideas?

Thanks
Nov 13 '05 #1
4 4459
Try call Access using the (undocumented or supported I think) /decompile
switch (still in AC 2003?) on a COPY of your database

For a while, I had to do this so much I created a shortcut while developing
that did it for me, whose target was:

"C:\Program Files\Microsoft Office\Office10\MSACCESS.EXE" /decompile "H:\My
Documents\project\foo.mdb"

Good luck

"DFS" <no****@nospam.com> wrote in message
news:10*************@corp.supernews.com...
"[database name] has detected corruption in this file. To try to repair the corruption, first make a backup copy of the file. Then, on the Tools menu, point to Database Utilities and click Compact and Repair database. If you
are currently trying to repair this corruption then you will need to
recreate this file or restore it from a previous backup."

I think it's my usage of the Excel 9.0 object library that's causing the
problem, but I can't be sure.

It's a corruption in one or all of the modules. None will open.

I can put forms in design mode, but can't add objects to them. I can
sometimes open tables.

None of the usual repair / recovery methods works:
* Compact and Repair
* create new db and import objects
* delete non-corrupt module, Compact and Repair
* export modules to another file

Any ideas?

Thanks

Nov 13 '05 #2
Best information and links on corruption and trying to fix it that I know
about are at MVP Tony Toews' site, http://www.granite.ab.ca/accsmstr.htm.
Take a look at those.

I never heard of using an Excel library of any version causing database
corruption. There are many causes, but that'd be a new one on me.

Larry Linson
Microsoft Access MVP

"DFS" <no****@nospam.com> wrote in message
news:10*************@corp.supernews.com...
"[database name] has detected corruption in this file. To try to repair the corruption, first make a backup copy of the file. Then, on the Tools menu, point to Database Utilities and click Compact and Repair database. If you
are currently trying to repair this corruption then you will need to
recreate this file or restore it from a previous backup."

I think it's my usage of the Excel 9.0 object library that's causing the
problem, but I can't be sure.

It's a corruption in one or all of the modules. None will open.

I can put forms in design mode, but can't add objects to them. I can
sometimes open tables.

None of the usual repair / recovery methods works:
* Compact and Repair
* create new db and import objects
* delete non-corrupt module, Compact and Repair
* export modules to another file

Any ideas?

Thanks

Nov 13 '05 #3
DFS
Malcolm Cook wrote:
Try call Access using the (undocumented or supported I think)
/decompile switch (still in AC 2003?) on a COPY of your database

For a while, I had to do this so much I created a shortcut while
developing that did it for me, whose target was:

"C:\Program Files\Microsoft Office\Office10\MSACCESS.EXE" /decompile
"H:\My Documents\project\foo.mdb"

Good luck
Thanks, but no cigar. Same error.


"DFS" <no****@nospam.com> wrote in message
news:10*************@corp.supernews.com...
"[database name] has detected corruption in this file. To try to
repair the corruption, first make a backup copy of the file. Then,
on the Tools menu, point to Database Utilities and click Compact and
Repair database. If you are currently trying to repair this
corruption then you will need to recreate this file or restore it
from a previous backup."

I think it's my usage of the Excel 9.0 object library that's causing
the problem, but I can't be sure.

It's a corruption in one or all of the modules. None will open.

I can put forms in design mode, but can't add objects to them. I can
sometimes open tables.

None of the usual repair / recovery methods works:
* Compact and Repair
* create new db and import objects
* delete non-corrupt module, Compact and Repair
* export modules to another file

Any ideas?

Thanks

Nov 13 '05 #4
DFS
Larry Linson wrote:
Best information and links on corruption and trying to fix it that I
know about are at MVP Tony Toews' site,
http://www.granite.ab.ca/accsmstr.htm. Take a look at those.

I never heard of using an Excel library of any version causing
database corruption. There are many causes, but that'd be a new one
on me.
Well, I had been working with and in a code block that uses the Excel
automation object when the corruption occurred.

Here's the automation code that runs fine once, but usually leaves the Excel
instance open in memory (use Task Mgr | Processes | End Process to close
it). The next time you try to run it, it crashes on
'objWB.Worksheets(1).Activate' (halfway down)

Dim objExcel As Excel.Application, objWB As Excel.Workbook, objWS As
Excel.Worksheet

Set objExcel = New Excel.Application
Set objWB = objExcel.Workbooks.Open(chosenFile)
For Each objWS In objWB.Worksheets
With objExcel
... do things with the sheet
End With
Next objWS

'LEAVE CURSOR IN A1 BEFORE SAVING SHEET
objWB.Worksheets(1).Activate
objWB.Worksheets(1).Range("A1:A1").Select
objWB.Worksheets(1).Range("A1").Activate

objExcel.ActiveWorkbook.Save

'CLOSE OBJECTS
Set objWS = Nothing
objWB.Close
Set objWB = Nothing
objExcel.Quit
Set objExcel = Nothing


Larry Linson
Microsoft Access MVP

"DFS" <no****@nospam.com> wrote in message
news:10*************@corp.supernews.com...
"[database name] has detected corruption in this file. To try to
repair the corruption, first make a backup copy of the file. Then,
on the Tools menu, point to Database Utilities and click Compact and
Repair database. If you are currently trying to repair this
corruption then you will need to recreate this file or restore it
from a previous backup."

I think it's my usage of the Excel 9.0 object library that's causing
the problem, but I can't be sure.

It's a corruption in one or all of the modules. None will open.

I can put forms in design mode, but can't add objects to them. I can
sometimes open tables.

None of the usual repair / recovery methods works:
* Compact and Repair
* create new db and import objects
* delete non-corrupt module, Compact and Repair
* export modules to another file

Any ideas?

Thanks

Nov 13 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

14 posts views Thread by JK Peck | last post: by
1 post views Thread by livre | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.