G
Guest
I'm working on a medication monitoring system for my clinic using Access
2003. One of the essential tasks of the system is to calculate a suggested
dosage range for the medication in response to a lab value. The lab value,
current dosage, suggested range, and follow-up dates are managed in a subform
(1 patient to many lab/rx records.)
I have two separate macros involved in this process. One calculates the
suggested lower end of the dosage range. The other calculates the suggested
high end of the dosage range.
I suspect that my design of these macros is less than elegant (duct tape and
spackle, actually!) They are set up as a series of conditional expressions.
The macros worked on the db as it was set up. I was out of the office for a
week. Although everyone swears they did not touch the db, the macros did not
run when I returned to the office. I have run them stepwise and see no
problems.
Here's the odd part. The macros still run on "old" patient records (entered
before ~1/20/05.) They don't run on "new" records. If I copy an "old" patient
record, paste it in using Table view, and change the chart number (primary
key, so it has to be changed), the macros DO run. If I enter a "new" patient
record via either form or table, the macros do NOT run.
There is one other macro in the subform - a warning box if the prescribed
dosage and the actually-taken dosage do not match. That runs in "old" or
"new" records with no problems. I've tried using RunMacro with each and both
of the dosage range mcrs *inside* the discrepancy warning macro and that has
not worked.
I have tried removing the macros / event procedures and adding them back in
one by one, individually and in combination, with no luck.
Help! I realize I'm way in over my head here, but it is so frustrating to
get this far and then take three giant steps back. At this point I have about
25 hours of my life invested in this project (plus another 5 hours today.) So
I am determined to sort this out one way or another.
Any ideas?
Thanks,
Heather
2003. One of the essential tasks of the system is to calculate a suggested
dosage range for the medication in response to a lab value. The lab value,
current dosage, suggested range, and follow-up dates are managed in a subform
(1 patient to many lab/rx records.)
I have two separate macros involved in this process. One calculates the
suggested lower end of the dosage range. The other calculates the suggested
high end of the dosage range.
I suspect that my design of these macros is less than elegant (duct tape and
spackle, actually!) They are set up as a series of conditional expressions.
The macros worked on the db as it was set up. I was out of the office for a
week. Although everyone swears they did not touch the db, the macros did not
run when I returned to the office. I have run them stepwise and see no
problems.
Here's the odd part. The macros still run on "old" patient records (entered
before ~1/20/05.) They don't run on "new" records. If I copy an "old" patient
record, paste it in using Table view, and change the chart number (primary
key, so it has to be changed), the macros DO run. If I enter a "new" patient
record via either form or table, the macros do NOT run.
There is one other macro in the subform - a warning box if the prescribed
dosage and the actually-taken dosage do not match. That runs in "old" or
"new" records with no problems. I've tried using RunMacro with each and both
of the dosage range mcrs *inside* the discrepancy warning macro and that has
not worked.
I have tried removing the macros / event procedures and adding them back in
one by one, individually and in combination, with no luck.
Help! I realize I'm way in over my head here, but it is so frustrating to
get this far and then take three giant steps back. At this point I have about
25 hours of my life invested in this project (plus another 5 hours today.) So
I am determined to sort this out one way or another.
Any ideas?
Thanks,
Heather