Edit Module On The Fly (1 Viewer)

Summerwind

Registered User.
Local time
Today, 02:42
Joined
Aug 25, 2005
Messages
91
I have searched the forum but can't find any help.

I have an application consisting of front and back ends being used by quite a few clients now.

As a result of feed-back, I have made some improvements to the app but these require changes to the structure of some of the existing tables in the back end. Obviously, clients are not going to be happy to lose exisiting data but I have working code to make the changes. So far, so good.

My problem is that I can't have the updating code run more than once, so when the client has installed the new front end, the code that makes the changes to the backend must not be called again.

I have tried the "Mod1.DeleteLines 3,1" code but I get an error message telling me that VBA can't break at this time.:(

I have tried using a module in a form as well as free standing, but still get the same results. Any help please?
 

SammyJ

Registered User.
Local time
Today, 09:42
Joined
Jan 9, 2006
Messages
57
Why wouldn't your code which makes the changes just not do anything if it had already been run. So if one of the things your code does is to add a field to a table for example, the code, before running would check that it isn't there already. So it will only ever run once.

But if making updates like this is a regular thing you might want to make the versioning more formal, and have a local table which knows its current version, and check in against a back end table, and if it is behind it would download a script from the back end which would make the changes, and then it could delete the script. The name of the script module could be given in the versioning table, and it could simply have a standard name for the routine.

Not sure why your code deleting method isn't working, but it seems like a messy solution.

Sam.
 

Summerwind

Registered User.
Local time
Today, 02:42
Joined
Aug 25, 2005
Messages
91
Hi Sam

Thanks for your reply.

I think I may well have to adopt a more formal approach to version updating as you suggest.

I am still puzzled as to why the module editing code doesn't work. Maybe someone else will have an answer.
 

Users who are viewing this thread

Top Bottom