I have an application (MP2) that uses an Access 2000 database. The system has a utility that the user runs at the start of each day to set the beginning work order number. We use the date + a sequential number starting with 1. I am trying to see if it is possible to write a script for Access to do this once a day the just for the first entry of each new day. I hasve looked all over the net, but not much luck at all. Any directions or links to a site that might help would be greatly appreciated! Thanks in advance!
Access 2000 Script
Collapse
X
-
Tags: None
-
Using RuralGuy's approach you probably don't need to run the script.
However, to run a script automatically, but only once per day, you would need some code in, say, the Open Event procedure of your switchboard (or whichever form is set to open on startup) that checks some sort of flag in a table (probably a date field set in a system management type table). If the flag indicates that the process has run already that day (The field is set to today's date for instance), then skip the routine, otherwise run it. The routine would need to include code to log the fact that it had run (Set the field to today's date).Comment
-
Thanks. The problem is that I do not have access to the code. It is a purchased program. The script would have to run when the user logged into the application, somehow? I tried going into the Access 2000 db table where it stores the next work order number, but it appears they have something hardcoded that writes to that table if you tell the application to auto assign the next number. Not sure if this is even possible for me to do. Thanks for the replies, though!Comment
-
If you are dealing with a purchased program then that's completely different. You probably shouldn't touch the code anyway, even if you can, as that may (quite sensibly) invalidate any support agreement you may have.
I suggest you contact your supplier and ask them what options they can suggest for your requirements.Comment
-
We are contractors for the Air Force. A company my boss used to work for used the same application nad they wrote an access script that ran when the user logged in to do what I am trying to do. We contacted them, but htey have since upgraded to a newer version (7i) and don't have the old scripts they used. Just thought someone here might have an idea of how I might go about doing it. Thanks for the help and responses anyways though! Will post back here if I find out how to do it...Comment
-
Comment