Greetings from Montreal
I am using PDOXWIN 1 and have a form with a one->many data model in which
the header, derived from the master table contains demographic info
including the primary key and in which the detail tables are represented
as table frames, one for each of several types of similar results (*
levels of different *) with some fields set to change colour if the
levels are too high and not otherwise. With the cursor in the primary key
field of the master table, scrolling goes from patient to patient, and
with the cursor in the date field of a detail table frame (one table
frame for each drug showing a single record of its table), scrolling goes
from one drug level result to another for the same drug in chronological
order for the same patient.
The problem is that different people take different combinations of
*, and so in scrolling from patient to patient, field values will be
(I imagine) unassigned in the table frames for * that someone doesnt
take. If the most recent result in a field was too high for a previous
patient, the colour will have been changed (to yellow) and will remain
that way with blank but yellow fields until a patient taking the drug and
with a normal value is encountered at which point the colour changes back
to normal as it should . This results in an ungainly patchwork much of
the time.
I have tried using DataArriveRecord in the action method of the primary
key to test for unassigned values of the result in the detail table and
if so, give them a value of zero and then do something like
if druglevl.value=0 then
druglevl.color=transparent
but this does not work and doesnt work in the NewValue method either.
Neither does anything attached to the druglevl field object's depart or
removeFocus methods, I guess because one is not calling them in a
scrolling operation and the field usually does not have focus anyway.
Similarly action/DataArriveRecord attached to the druglevl or date field
of a detail table doesnt work, I guess because the record giving the
problem is unassigned and there is thus no record upon which one arrives.
My apologies for the long post, but I would be grateful for any insight
into this.
Thank you in advance and season's greetings.
(Usual disclaimer)
Benjamin G. Zifkin,MD