Hello, trying to use Date Calculator for the first time.
I was able to successfully use the snippet for 'Days from Discharge to SOC'
However, when I copied and pasted the same snippet, but changed the names of the dates (Psoc and daysdc), they are not independent from the original snippet. Whatever I choose for 'Days from Discharge to SOC' calculates the number of days for 'Days from Discharge until prompted SOC Date' despite different dates.
Any help is greatly appreciated.
Can you share the snippet with me so I can take a look? You can either share it with my email (dylan@blaze.today) or click the gear icon and then copy/paste the snippet here in the community.
Days from Discharge until prompted SOC Date
Date patient was discharged from facility: {formdate: YYYY-MM-DD; name=daysdc} and date of prompted SOC: {formdate: YYYY-MM-DD; name=Psoc}. There are {=floor(diff/(606024))} days from discharge to prompted SOC date.
{note}{diff=abs({time: X; at={=daysdc}}-{time: X; at={=Psoc}})}{endnote: trim=yes}
Days from Discharge to SOC
Date patient was discharged from facility: {formdate: YYYY-MM-DD; name=dc} and date patient's SOC was performed: {formdate: YYYY-MM-DD; name=soc}. There are {=floor(diff/(606024))} days from DC date to SOC date.
{note}{diff=abs({time: X; at={=dc}}-{time: X; at={=soc}})}{endnote: trim=no}
Days from Discharge until prompted SOC Date
Date patient was discharged from facility: {formdate: YYYY-MM-DD; name=daysdc} and date of prompted SOC: {formdate: YYYY-MM-DD; name=Psoc}. There are {=datetimediff(daysdc, psoc, "D")} days from discharge to prompted SOC date.
Days from Discharge to SOC
Date patient was discharged from facility: {formdate: YYYY-MM-DD; name=dc} and date patient's SOC was performed: {formdate: YYYY-MM-DD; name=soc}. There are {=datetimediff(dc, soc, "D")} days from DC date to SOC date.
I am currently working on a similar snippet, but instead of dates, it is calculating time.
Is there a way to use my current snippet:
On {formdate: MM/DD/YYYY} at {formdate: HH:mm} I called ...
The call concluded at {formdate: HH:mm} for a duration of (insert a box that calculates call duration.
Or do I have to use 1 of 2 formulas from the Textblaze Hours Calculator page?
I appreciate you and all of your help!
On {formdate: MM/DD/YYYY} at {formdate: HH:mm; name=starttime} I called ...
The call concluded at {formdate: HH:mm; name=endtime} for a duration of {difference=datetimediff({=datetimeparse(starttime, "HH:mm")}, {=datetimeparse(endtime, "HH:mm")}, "m")}{=difference} {if: difference=1}minute{else}minutes{endif}.