Notifications
Clear all
Topic starter
Hi has anyone ever had to reset an obs term to zero if todays date is in a certian month?
Sincerely
Theresa Savage
Posted : June 18, 2013 4:18 am
You can parse the month out of a date like this:
if val(get(getfield(str(DOCUMENT.CLINICALDATE),"/ ",""),1)) == 6 then OBSNOW("term", 0) endif
(I usually use the document's clinical date but ._TODAYSDATE might also work)
Posted : June 18, 2013 8:14 am
Topic starter
I will try that
Thank You
Posted : June 19, 2013 2:22 am
Topic starter
Thank you that worked!!!
Posted : June 19, 2013 6:45 am
if(sub(str(._TODAYSDATE),1,2)=="06")then
OBSNOW("obsterm","0")
endif
will work if you want today's date rather than the date the update was started.
Posted : June 21, 2013 2:47 am
Topic starter
Thank you!!!
Posted : June 21, 2013 3:58 am