In VFE, I would like a runprocess button to record two different obs terms.
Is this possible? If so, what does the code look like?
Thanks in advance for any advice.
Good Afternoon,
The code may look something like this.
{
obsnow("obs1","new value")
obsnow("obs2","new value")
}
"obsnow()" is a function that accepts some parameters.
obsnow("obsname") will return the value that is currently stored in the obsterm "obsname"
obsnow("obsname","valuetoset") will set the value in the obsterm "obsname"
obsnow("obsname","valuetoset","date") will set the value in the obsterm "obsname" with the date specified.
I hope this helps!
(Other Examples)
{
obsnow("weight","70")
obsnow("weight",document.weight)
obsnow("weight",obsprev("weight") )
}
-James Caswell
Thank You.
Can you tell me what is wrong with this? The button is not doing/recording anything.
{fnAddInstr_CHUGCVS(OBSNOW("INSTRUCTIONS") ,"St. Al's Sleep Study'") OBSNOW("CMPSPPPTED") ,"Handout Printed'") +
CVS_Print(40)}
Thanks
Sorry, can't explain what is wrong above but I can show you the code we use to do something similar...The code below is all in 1 run process button
PRINTHANDOUT("Handouts\Enterprise\Work Release")
OBSNOW("HANDOUTSPRTD","Work Release Printed")
OBSNOW("EFTRACK100", "Y")
Thank you (Akoen), that looks pretty simple.
What exactly is EFTRACK100, how are these stored?
Also, what if you print multiple handouts how do you store them in obsterms?
Thanks again.
I am uncertain what is exactly causing your error. Some of these functions look custom/foreign to me. Try the structuring the code as below:
{
fnAddInstr_CHUGCVS(OBSNOW(“INSTRUCTIONS”) ,”St. Al’s Sleep Study’”)
OBSNOW(“CMPSPPPTED” ,”Handout Printed’”)
CVS_Print(40)
}
If you continue getting no response, you can run a "MEL_Trace" and look at the log to get some clues as to where it is breaking down.
To do this go to the button, hit ctrl+shift+m (To start the logging), press the button, hit ctrl+shift+m (To stop the logging).
Then go to "%localappdata%\Centricity\Logs" (You can type this into an explorer window)
Open the "TraceMel.txt" document and scroll through this looking for errors.
This seems to work, Thank You.
Now, I would like to add : "Patient Handout was printed" to the text of the document.
What would this look like?
Sorry, Im not great with the particulars of MEL code (yet).
Thanks for your time!