Hi - I'm trying to make a form for manual lab entry, similar to the CCC lab entry forms (that push to the flowsheet), because I dont like the layout (translation) in the chart note of the CCC lab entry forms. I making my own but the only problem I am having is being able to specify the date that the labs were done. I have looked in the forums archive and found some MEL runprocess threads on this but cannot seem to get them to work. Has anyone had success doing this?
Thanks!
Matt
I'm not familiar with what CCC does, but here's what we use. Hopefully, this helps.
The Value field is DOCUMENT.HGBA1C_NEW.
The Date field is DOCUMENT.HGBA1C_DATE
The Record button's code:
{rec_HgbA1c()}{ DOCUMENT.HGBA1C_DATE=
""}
{DOCUMENT.HGBA1C_NEW =
""}
The {rec_HgbA1c()} function used in the Record button:
{fn rec_HgbA1c(){IF (mtch_dt(DOCUMENT.HGBA1C_DATE) == TRUE AND DOCUMENT.HGBA1C_NEW <> "")
THEN OBSNOW("HGBA1C", DOCUMENT.HGBA1C_NEW, DOCUMENT.HGBA1C_DATE)
ELSE USEROK("Please enter a valid date and/or value") ENDIF}}
Exactly how I do it for ours also.
Matt, If you want, I can post one of mine that shows this.
Thank you both. I would like to see yours Ernie if you dont mind.
My concern with the above is that there is a "record" button and a date field for each lab rather than 1 single "record" button and 1 single date field to push all entered labs to the flowsheet at one time. Any work around for this?
Very close! Would be ideal if therre were 1 record button to enter all the lab values at one time. I'm teaching myself this stuff so I doubt i will be able to figure out how to do that but I will try. Any ideas would be greatly appreciated...
Thanks
Matt
You could do that fairly easy. Basically take the code in the record button and put it in one button. I can post a example tomorrow.
Ok - So if I had lots of labs on a page I would just copy that code multiple times (with changes for the appropriate lab and obsterm in each copy) to a single button/runprocess? That would be a very long runprocess code. Would it be better to make a function out of it and have the button run the function? I'm very new to this so that may not even make sense 🙂 - hopefully it does.
I would use a function. I have modified the form a little. Here is how I think you are wanting to do it.
Success! Worked perfectly. I can certainly edit it form here. Thank you!
Your welcome.