A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Access 2007 Object Corruption



 
 
Thread Tools Display Modes
  #1  
Old March 3rd, 2009, 04:23 AM posted to microsoft.public.access
CrazyAccessProgrammer
external usenet poster
 
Posts: 58
Default Access 2007 Object Corruption

Have been using Access since Access 97. Been programming with Access 2007 now
for about a month. It's very dissappointing how often objects become corrupt.
I seem to spend more time fixing object corruption than anything else. Hope a
future patch of Access can calm this down at least a bit.
  #2  
Old March 3rd, 2009, 04:43 AM posted to microsoft.public.access
Allen Browne
external usenet poster
 
Posts: 11,706
Default Access 2007 Object Corruption

Can you pin down:
a) the kinds of corruption you are experience, and
b) the situations where this arises.

It is when modifying forms/reports? Or only when modifying data (e.g. in an
MDE where the objects themselves cannot be modified)?

Are there any consistent factors: subforms? Editing while the code window is
in break mode? Databases converted from a previous version?

What about the usual things? Name AutoCorrect off? SP1 applied? Decompile
tried?

Guidelines for avoiding corruption (not specific to A2007):
http://allenbrowne.com/ser-25.html

Guidelines for uncorrupting a database:
http://allenbrowne.com/recover.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"CrazyAccessProgrammer"
wrote in message
...
Have been using Access since Access 97. Been programming with Access 2007
now
for about a month. It's very dissappointing how often objects become
corrupt.
I seem to spend more time fixing object corruption than anything else.
Hope a
future patch of Access can calm this down at least a bit.


  #3  
Old March 3rd, 2009, 02:36 PM posted to microsoft.public.access
a a r o n _ k e m p f
external usenet poster
 
Posts: 415
Default Access 2007 Object Corruption

Jet corrupts all the time. It's a fact and that is why Jet has been
obsolete for the past decade.

Upsize to SQL Server if you want to maintain _ANY_ uptime.

-Aaron


On Mar 2, 8:43*pm, "Allen Browne" wrote:
Can you pin down:
a) the kinds of corruption you are experience, and
b) the situations where this arises.

It is when modifying forms/reports? Or only when modifying data (e.g. in an
MDE where the objects themselves cannot be modified)?

Are there any consistent factors: subforms? Editing while the code window is
in break mode? Databases converted from a previous version?

What about the usual things? Name AutoCorrect off? SP1 applied? Decompile
tried?

Guidelines for avoiding corruption (not specific to A2007):
* *http://allenbrowne.com/ser-25.html

Guidelines for uncorrupting a database:
* *http://allenbrowne.com/recover.html

--
Allen Browne - Microsoft MVP. *Perth, Western Australia
Tips for Access users -http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"CrazyAccessProgrammer"
wrote in ....

Have been using Access since Access 97. Been programming with Access 2007
now
for about a month. It's very dissappointing how often objects become
corrupt.
I seem to spend more time fixing object corruption than anything else.
Hope a
future patch of Access can calm this down at least a bit.


  #4  
Old March 3rd, 2009, 03:20 PM posted to microsoft.public.access
CrazyAccessProgrammer
external usenet poster
 
Posts: 58
Default Access 2007 Object Corruption

"Can you pin down the kinds of corruption you are experience"

I'm unable to determine where the corruption is. I try copying in backup
objects (tables, forms, modules etc.) from a known 'good' backup of my
database to the one I'm working on that is experiencing corruption, but
always without luck. In the end, I have to go back to my last 'good' backup
of my database and redo whatever work I had done since that 'good' copy...
all the while hoping I don't corrupt yet again.

"Can you pin down the situations where this arises"


Usually after a runtime error of my VBA code. Though there is no rhyme or
reason to it. It doesn't seem to matter if the code that errored out was
doing something complex or something simple. Or if the error was caused by a
complex number of processes erroring out during the middle of its execution
or by a simple syntax error.

"Is It when modifying forms/reports? Or only when modifying data (e.g. in an MDE where the objects themselves cannot be modified)?"


The corruption is happening with a form I've been working and coding on. I
am NOT currently working on the database in MDE form.

"Are there any consistent factors: subforms?"


No subforms are involved in the form I'm working on at this point.

"Are there any consistent factors: Editing while the code window is
in break mode?"


Yes, I am guilty of this. But I do this rarely and it doesn't account for
the vast majority of times I end up with a corrupted database.

"Are there any consistent factors: Databases converted from a previous version?"


The database I'm working on is a brand new database started from scratch
using Access 2007, fully patched as of this writing.

"Are there any consistent factors?"

Right now I'm coding custom actions for the OnDelete event in my form. I've
noticed here in particular that any untrapped runtime error that occurs
during the form's OnDelete event will result in corruption of my database,
probably 9 times out of 10.

"What about the usual things? Name AutoCorrect off?"


Yes, Name AutoCorrect is off.

"What about the usual things? SP1 applied?"


Yes, SP1 is applied.

"What about the usual things? Decompile tried?"


Yes, one of the first things I try to do is decompile when I'm experiencing
database corruption. It never seems to resolve anything however.

"Guidelines for avoiding corruption (not specific to A2007): http://allenbrowne.com/ser-25.html


Guidelines for uncorrupting a database:
http://allenbrowne.com/recover.html"


I have previously asked for resources on this forum regarding how to avoid
Access corruption and have been pointed to the links above. I've read those
resources and a few others and try to always work in a way to avoid known
ways of corrupting my database.

In the end, it seems Access 2007 is worse in this department compared to my
experiences working with Access 97, Access 2000, & Access 2003.
  #5  
Old March 3rd, 2009, 03:22 PM posted to microsoft.public.access
CrazyAccessProgrammer
external usenet poster
 
Posts: 58
Default Access 2007 Object Corruption

While I'm frustrated with how often Access 2007 is corrupting on me during
development of my database, what you wrote is quite an exageration relative
to my actual experience with Jet. It's not as bad, at least to me, as you
suggest.


"a a r o n _ k e m p f" wrote:

Jet corrupts all the time. It's a fact and that is why Jet has been
obsolete for the past decade.

Upsize to SQL Server if you want to maintain _ANY_ uptime.

-Aaron


On Mar 2, 8:43 pm, "Allen Browne" wrote:
Can you pin down:
a) the kinds of corruption you are experience, and
b) the situations where this arises.

It is when modifying forms/reports? Or only when modifying data (e.g. in an
MDE where the objects themselves cannot be modified)?

Are there any consistent factors: subforms? Editing while the code window is
in break mode? Databases converted from a previous version?

What about the usual things? Name AutoCorrect off? SP1 applied? Decompile
tried?

Guidelines for avoiding corruption (not specific to A2007):
http://allenbrowne.com/ser-25.html

Guidelines for uncorrupting a database:
http://allenbrowne.com/recover.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users -http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"CrazyAccessProgrammer"
wrote in ....

Have been using Access since Access 97. Been programming with Access 2007
now
for about a month. It's very dissappointing how often objects become
corrupt.
I seem to spend more time fixing object corruption than anything else.
Hope a
future patch of Access can calm this down at least a bit.



  #6  
Old March 3rd, 2009, 06:59 PM posted to microsoft.public.access
BruceM[_2_]
external usenet poster
 
Posts: 1,763
Default Access 2007 Object Corruption

Aaron infests this newsgroup from time to time with his rants against
Access/Jet. SQL Server is his answer to everything, yet he seems not to be
welcome in any of the SQL Server groups.

I am not very familiar with Access 2007, but I have not heard that it is
particularly prone to corruption. Here are a couple of things you could
check:
http://allenbrowne.com/bug-03.html
http://allenbrowne.com/Access2007.html

Also, there are some bugs listed here (various places on the page):
http://allenbrowne.com/tips.html

One mo
http://allenbrowne.com/Access2007.html#Bugs

There are other sites, I am sure, but Allen's site has a good consolidated
listing. A search about a specific problem may well turn up further
information.

"CrazyAccessProgrammer"
wrote in message ...
While I'm frustrated with how often Access 2007 is corrupting on me during
development of my database, what you wrote is quite an exageration
relative
to my actual experience with Jet. It's not as bad, at least to me, as you
suggest.


"a a r o n _ k e m p f" wrote:

Jet corrupts all the time. It's a fact and that is why Jet has been
obsolete for the past decade.

Upsize to SQL Server if you want to maintain _ANY_ uptime.

-Aaron


On Mar 2, 8:43 pm, "Allen Browne" wrote:
Can you pin down:
a) the kinds of corruption you are experience, and
b) the situations where this arises.

It is when modifying forms/reports? Or only when modifying data (e.g.
in an
MDE where the objects themselves cannot be modified)?

Are there any consistent factors: subforms? Editing while the code
window is
in break mode? Databases converted from a previous version?

What about the usual things? Name AutoCorrect off? SP1 applied?
Decompile
tried?

Guidelines for avoiding corruption (not specific to A2007):
http://allenbrowne.com/ser-25.html

Guidelines for uncorrupting a database:
http://allenbrowne.com/recover.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users -http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"CrazyAccessProgrammer"

wrote in
....

Have been using Access since Access 97. Been programming with Access
2007
now
for about a month. It's very dissappointing how often objects become
corrupt.
I seem to spend more time fixing object corruption than anything
else.
Hope a
future patch of Access can calm this down at least a bit.




  #7  
Old March 4th, 2009, 03:56 AM posted to microsoft.public.access
David W. Fenton
external usenet poster
 
Posts: 3,373
Default Access 2007 Object Corruption

=?Utf-8?B?Q3JhenlBY2Nlc3NQcm9ncmFtbWVy?=
wrote in
:

I try copying in backup
objects (tables, forms, modules etc.)


Your app is not split. That's the first thing I'd rectify.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
  #8  
Old March 4th, 2009, 03:58 AM posted to microsoft.public.access
David W. Fenton
external usenet poster
 
Posts: 3,373
Default Access 2007 Object Corruption

"BruceM" wrote in
:

Aaron infests this newsgroup from time to time with his rants
against Access/Jet. SQL Server is his answer to everything, yet
he seems not to be welcome in any of the SQL Server groups.


He really doesn't know anything about SQL Server, either.

I think he's a very clever performance artist, knowingly posting
completely stupid and wrong things in an effort to make the rest of
us "perform."

I'd suggest completely ignoring him.

Alternatively, taunt him with his inability to stop responding to
criticisms of the errors in his posts -- that's good for a laugh
every now and then.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
  #9  
Old March 4th, 2009, 06:04 AM posted to microsoft.public.access
Allen Browne
external usenet poster
 
Posts: 11,706
Default Access 2007 Object Corruption

Thanks: the extra detail helps understand when this occurs.

If you have not split the database, and it is being opened by multiple users
(or even multiple instances on your own computer), David's suggestion of
splitting will help. I assume you know what we are talking about he
tables in one file in a shared location (the back end), and all other
objects (queries, forms, reports, code, ...) and attached tables in a
seprate file (the front end) such that each user opens an indepdent copy of
the front end.

Editing code in break mode can cause corruption IME. Merely pausing in break
mode (followed by a continue or reset) should not corrupt the file (unless
it affects some other dependences between classes or objects that disappear
when you reset.)

When you start modifying the design of a form, Access creates a backup
(which it will restore if you discard your current design changes.) When you
edit a form's module, it also creates a back up of the module. Consider what
happens if you open a form in Form view (not design view), start using it,
and then go to break mode. At this point, there is at least 1 copy of the
form, plus 2 copies of the code (the text version you view in the IDE, and
the compiled code that's running, which may or may not be saved.) Now if you
start editing the code in break mode, Access has to create a backup copy of
the code, and keep track of the backup to restore (with or without the saved
compiled code), plus the one being edited (which may or may not get saved in
the end), while actually still handling the compiled version that's running
(in break mode), and keep track of all this stuff correctly. It actually
does a pretty reasonable job of this most of the time, but IME there are
cases where it gets confused. You end up with a corrupt form, breakpoints
that don't break, code that executes which no longer exists in the module
(when you read the text version), or some other kind of corruption. And that
gets confused further by interacting with other bugs (such as with the
AccessField type where a form's module refuses to compile when it used to),
or inconsistencies between the forms in MSysObjects and those in AllForms.

I have no reason to think that A2007 is better/worse than other versions
with all of that.

But there is another factor with the Delete event. When Form_Delete fires,
Access has begun an implicit transaction that will be committed or rolled
back between BeforeDelConfirm and AfterDelConfirm. If you are experiencing
corruption when you interrupt it while the implicit transaction is active
(particularly if there are multiple users in the same file), I wonder if
something may be going wrong there?

Sorry: I can't be more specific. Hope that just talking about it may suggest
something that's worth considering, so you can find a path around whatever
is triggering this corruption.

IME, it's quite rare to get corruption of a completed project (where you are
not modifying forms/reports/code, e.g. of an MDE), but pretty common during
development.

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"CrazyAccessProgrammer"
wrote in message
...
"Can you pin down the kinds of corruption you are experience"


I'm unable to determine where the corruption is. I try copying in backup
objects (tables, forms, modules etc.) from a known 'good' backup of my
database to the one I'm working on that is experiencing corruption, but
always without luck. In the end, I have to go back to my last 'good'
backup
of my database and redo whatever work I had done since that 'good' copy...
all the while hoping I don't corrupt yet again.

"Can you pin down the situations where this arises"


Usually after a runtime error of my VBA code. Though there is no rhyme or
reason to it. It doesn't seem to matter if the code that errored out was
doing something complex or something simple. Or if the error was caused by
a
complex number of processes erroring out during the middle of its
execution
or by a simple syntax error.

"Is It when modifying forms/reports? Or only when modifying data (e.g. in
an MDE where the objects themselves cannot be modified)?"


The corruption is happening with a form I've been working and coding on. I
am NOT currently working on the database in MDE form.

"Are there any consistent factors: subforms?"


No subforms are involved in the form I'm working on at this point.

"Are there any consistent factors: Editing while the code window is
in break mode?"


Yes, I am guilty of this. But I do this rarely and it doesn't account for
the vast majority of times I end up with a corrupted database.

"Are there any consistent factors: Databases converted from a previous
version?"


The database I'm working on is a brand new database started from scratch
using Access 2007, fully patched as of this writing.

"Are there any consistent factors?"

Right now I'm coding custom actions for the OnDelete event in my form.
I've
noticed here in particular that any untrapped runtime error that occurs
during the form's OnDelete event will result in corruption of my database,
probably 9 times out of 10.

"What about the usual things? Name AutoCorrect off?"


Yes, Name AutoCorrect is off.

"What about the usual things? SP1 applied?"


Yes, SP1 is applied.

"What about the usual things? Decompile tried?"


Yes, one of the first things I try to do is decompile when I'm
experiencing
database corruption. It never seems to resolve anything however.

"Guidelines for avoiding corruption (not specific to A2007):
http://allenbrowne.com/ser-25.html


Guidelines for uncorrupting a database:
http://allenbrowne.com/recover.html"


I have previously asked for resources on this forum regarding how to avoid
Access corruption and have been pointed to the links above. I've read
those
resources and a few others and try to always work in a way to avoid known
ways of corrupting my database.

In the end, it seems Access 2007 is worse in this department compared to
my
experiences working with Access 97, Access 2000, & Access 2003.


  #10  
Old March 4th, 2009, 04:38 PM posted to microsoft.public.access
CrazyAccessProgrammer
external usenet poster
 
Posts: 58
Default Access 2007 Object Corruption

I do understand that splitting the tables away to a backend file is important
and every finished Access application I make is set up in this way (front end
client with forms/reports/modules/queries etc and a back end with the tables).

At this stage in my development, the database has about 5 tables. Usually at
this stage of the game I keep the tables in the same file as all the other
objects to make developing less of a hassle. When the tables reach about 20
in number is when I usually make the split.

"David W. Fenton" wrote:

=?Utf-8?B?Q3JhenlBY2Nlc3NQcm9ncmFtbWVy?=
wrote in
:

I try copying in backup
objects (tables, forms, modules etc.)


Your app is not split. That's the first thing I'd rectify.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:54 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.