I have the following Custom Fields:
Start Date
End Date
Step 1 (Days)
Step 2 (Days)
Step 3 (Days)
Step 4 (Days)
Start Date I have a button which does that. End Date I want it to calculate based off days I have in Step 1-4 and add it to the Start Date, so if my Start Date is November 21 and Step 1 takes 1, step 2 takes 1, step 3 takes 1 and step 4 takes 1 day then my end date should be November 25 (4 days), is there a way to make a button or automation to be able to this.
@Ashish Dobriyal yes this should be possible! I'm not sure if you can achieve this all within one rule though (someone else might prove me wrong though!). You might need to create another "total" field then use butler to calculate the total duration (see custom field arithmetic here).
Then use date arithmetic to add this number to the start date. E.g.
when custom field "Total" is set, set custom field "End Date" to "{{%Start Date}+{{%Total}}d}”
Try
Set custom field "End Date" to "{{%Start Date}+({{%Step 1 (Days)}}+{{%Step 2 (Days)}}+{{%Step 3 (Days)}}+{{%Step 4 (Days)}})d}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When I try creating the button, it doesn't let me choose End Date as a Custom Field, I can't choose anything that's a Date. I'm assuming the trigger is Set Custom Field "End Date" to new value and that's the rest of what you said.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Ashish Dobriyal I believe it's a dropdown field, but you should be able to type the field name as well. Just make sure you spell it word for word.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I typed in the field name and I added this formula for the new value:
"{{%START DATE}+({{STEP 1}}+{{STEP 2}}+{{STEP 3}}+{{STEP 4}}+{{STEP 5}}+{{STEP 6}})d}
When I look at the formula in Create a button page there is a \ added before Start Date:
set custom field "END DATE" to "\"{{%START DATE}+({{STEP 1}}+{{STEP 2}}+{{STEP 3}}+{{STEP 4}}+{{STEP 5}}+{{STEP 6}})d}"
When I click the button I get the following error:
Couldn't read a date in ""{{%START DATE}+({{STEP 1}}+{{STEP 2}}+{{STEP 3}}+{{STEP 4}}+{{STEP 5}}+{{STEP 6}})d}".
I did change custom fields name from my initial questions so these are the exact names of the fields word for word.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.