How to add 1 hour to a DateTime field in Multiple Actions?

edited February 17, 2020 in Questions
I have a DateTime field that I would like to add 1 hour to in a multiple action.

I have set the multiple action to update the destination field (which is also a DateTime field and both are selected in the Model) by setting the option to a specific date and then I used {{$}} as the value but I am not sure of the syntax or format to add 1 hour to the value?


  • Rob HatchRob Hatch 🛠️ 
    edited September 1, 2016
    This is almost always going to be a javascript statement.  Fortunately - one of the actions you can invoke in the actions framework is a "snippet"    The snippet you'd write would convert the date/time field to a javascript object.  Add an hour to that object,  convert it back to a salesforce object and then save the field. 

    Should be pretty straightforward. 
  • edited February 17, 2020
    Thanks Rob.

    For us Javascript newbies do you have a sample pleeeaaaase?
  • edited September 30, 2016
    If you're using a datetime field change "parseSFDate" and "getSFDate" to "parseSFDateTime" and "getSFDateTime".
  • edited February 17, 2020
    Thanks Moshe.  

    You are a *  !!!
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!