1

I have an INSTANCETABLE for a repeated instrument (DRUGS) nested within another repeated instrument (VISIT). I can have multiple visits and for each visit multiple drugs.

Now, given that drugs do not change often from visit to visit, once I create a new visit, I would like to copy the data from the previous instances in DRUGS, basically all instances of DRUGS corresponding to the previous instance of VISIT.

Any suggestion?

Thanks

I tried using extension module Copy Data on Save but without success

1 Answers1

0

Presumably you are using the @INSTANCETABLE_REF tag to have the table on the "Visit" form show only the instances of the "Drugs" form that are related to the particular Visit instance you're viewing?

Rather than doing that, how about specifying a filter so the table shows all drug instances that are still active, e.g. do not hve a ceased date? @INSTANCETABLE_FILTER=[ceasedt]='' "

To me the idea of copying the drug data does not sound like an ideal solution.