Discussion Locked

Invalid name "Modules" in Access

0 helpful
8 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Searching through some old stuff archived on my employer's Server, I found an Engineering Estimating application in Access, developed by a long departed collegue, which could be of interest/use with a bit of a workover.

It was developed in a pre Access 97 version.
Upon opening/converting (in 97 & 2000), a message to the effect that "Modules" is an invalid name, and the process is not completed. I've tried running "Database Repair" with no change in message.

I've imported all of the Tables,Queries, Reports & Macros OK into a new Database but again "Modules" stops the import of Modules.

The application runs about 60% of the functions & I guess the lack of the Modules is affecting the rest of the application.

I presume from the message, that there is a module named "Modules" in Modules.
Is there any way of accessing this improperly (invalid) named "Modules" module to rename it appropriately?

Regards
Ken F

8 replies

by crowmoor

The problems is that Access before 97 used a programming language that was called Access-Basic and had a lot of differences from teh current VBA. Access 2000 can?t convert it.

I am not entirly sure but I think you could convert the database to 97-format with an Access 97 installation and from there raise it to 2000. But I suppose you have to do some code rewriting.

There are som utilities that could rewrite the code for you. Dont know where to find them anymore.

Also try to import all objects and use Copy Paste for all code. And afterwards correct all syntaxerrors.

Good luck. It isn?t an easy task but its manageble. If you further questions dont hesitate to mail me.

Jesper

by acdc

Thanks for the reply but I don't think this will assist this particular problem.
Both Access 97 & 2000 will import all of the Objects into a new DB but both give the same error message re invalid name "Modules" when attemping to import Modules.
I believe that a file within Modules was improperly named as "Modules" and that this is preventing Modules from opening.
Thanks for your reply,
Regards Ken F.

by otl

It may be that from 95 it will not translate to 97, been there and seen that. Had to rebuild/unlock the forms/macros to be able to import. May need a copy of 95, to go side by side with 97 to copy/unlock modules to be able to import all data/scripts/macros.

by acdc

Although the result isn't the one I was hoping for, many thanks for taking the time to reply.
Kind Regards,

Ken F

by dsa

FMS has a tool CODETOOLS that can list and make global changes on all the variable names, object names, etc. You have to buy it for the version of access that the program was written.

Otherwise, unless you still have the old version of access where you can run the program, it is not going to be worth your time reviving an old program. It would probably be faster to create a new program that will do the same thing.

by acdc

Thanks for your reply. It looks as though the start again option might be the best option.
Regards,
Ken F

This discussion is closed to new replies.