I have a formula tool that calculates by default the first monday of the week. I also have a text box tool that allows the user to override the formula tool date by inputting their date of their choice. I am using an update value with formula
that says if the text date is empty, then use the default date from the formula tool otherwise, use the input date.
However, I am not able to get the updated date reflected by the manual text input. Attached is the workflow
Solved! Go to Solution.
Hi @hlau117 ,
In your replace function, you need to use quotes in your second parameter and also, since your user is passing a date, you need to guarantee that you will have your date surronded by quotes.
I standardized your formula using double quotes in all formulas to use ' as the second parameter delimiter.
IF isEmpty([#1]) THEN '1' ELSE REPLACE([Destination],'DateTimeFormat(DATETIMEADD(DateTimeToday(),- IF TONUMBER(DATETIMEFORMAT(DateTimeToday(),"%w"))=0 THEN 7 ELSE TONUMBER(DATETIMEFORMAT(DateTimeToday(),"%w"))ENDIF +1,"days"),"%m-%d-%Y")', "'"+[#1]+"'") ENDIF
Best,
Fernando Vizcaino