Module corruption

  • Thread starter Thread starter SAL
  • Start date Start date
S

SAL

Has anyone ever seen this before?
I have an Access 2002 project file (connected to SQL Server 2005). When I
try to open the code window, Access crashes. I've narrow the problem down to
one module so I'm guessing there's corruption in that module.
I created a new project file and imported all the forms. I can import all
the modules except for one. Is there any way to retrieve the one module
that's causing the crash that anyone knows of? I've tried a repair several
times

Thanks for any help on this...

S
 
Hi SAL,

Try opening your database with the undocumented /decompile switch. If you
only have one version of Access installed on your machine, then you can click
on Start > Run and enter the following:

msaccess /decompile


The next database you open will have it's compiled "P" code discarded. Do a
compact and repair (holding down the shift key to disable any startup
routine). Then open any module and try clicking on Debug > Compile
ProjectName.

**If you have more than one version of Access, create a shortcut that points
to the correct version of msaccess.exe (enclosed in double quotes). Then add
on the space + /decompile part to the shortcut's target.


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
Thanks Tom.
I'll try that. I can just recheck the "P" code right?
Is the "P" code the Compile on demand option?

S
 
worked nicely Tom. Thanks

S

Tom Wickerath said:
Hi SAL,

Try opening your database with the undocumented /decompile switch. If you
only have one version of Access installed on your machine, then you can
click
on Start > Run and enter the following:

msaccess /decompile


The next database you open will have it's compiled "P" code discarded. Do
a
compact and repair (holding down the shift key to disable any startup
routine). Then open any module and try clicking on Debug > Compile
ProjectName.

**If you have more than one version of Access, create a shortcut that
points
to the correct version of msaccess.exe (enclosed in double quotes). Then
add
on the space + /decompile part to the shortcut's target.


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
Hi SAL,

Good to hear. Thanks for reporting this back.

In answer to the question you left in the other reply:
Is the "P" code the Compile on demand option?

No. However, I strongly recommend that you disable (uncheck) the Compile on
Demand option. You can read more about this here (scroll down a bit on page):

Always Use Option Explicit
http://www.access.qbuilt.com/html/gem_tips.html#VBEOptions

Michael Kaplan gives a good explaination of the undocumented decomile
switch, and "P" code:

www.trigeminal.com

See article #4, here:
http://www.trigeminal.com/usenet/usenet.asp?1033


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
Wow, scary... :)

S

Tom Wickerath said:
Hi SAL,

Good to hear. Thanks for reporting this back.

In answer to the question you left in the other reply:


No. However, I strongly recommend that you disable (uncheck) the Compile
on
Demand option. You can read more about this here (scroll down a bit on
page):

Always Use Option Explicit
http://www.access.qbuilt.com/html/gem_tips.html#VBEOptions

Michael Kaplan gives a good explaination of the undocumented decomile
switch, and "P" code:

www.trigeminal.com

See article #4, here:
http://www.trigeminal.com/usenet/usenet.asp?1033


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
Back
Top