|
Working on a way to capture various data when a code is present for the data line. But, keep getting syntax errors. I know that it looks over-kill, but once I get this much, then I can add lots more data manipulation logic to the structure.
I define a Formula Field called key_data and the Formula Workshop defines as follows:
whilePrintingRecords; shared numberVar pat_HBA1C; shared numberVar pat_date_HBA1C; shared numberVar pat_LDL; //See if a change of Patient ID; if so, clear the variables if {OBS.PID} <> previous({OBS.PID}) then ( pat_HBA1C := 0; pat_date_HBA1C := 0; pat_LDL :=0; ) else //Check for the HBA1C obs code ( if {OBS.HDID} = 28.00 then ( pat_HBA1C := {OBS.OBSVALUE}; pat_HBA1C_date_HBA1C := {OBS.OBSDATE}; ) //Check for the LDL obs code if {OBS.HDID} = 30.00 then ( pat_LDL := {OBS.OBSVALUE} ) )
Edited by joeyg13 - 26 Jan 2011 at 4:57am
|