Kansas City PowerApps and Flow User Group

Please login or click SIGN UP FOR FREE to create your PowerPlatformUG account to join this user group.
Expand all | Collapse all

addDays Expression

  • 1.  addDays Expression

    Posted Oct 28, 2019 11:02 AM
    Hello!

    I am trying to create addDays expression to my flow. I am trying to add seven days to the estimated close date. I am receiving the following error. Any ideas or suggestions?

    Unable to process template language expressions in action 'List_Opportunities' inputs at line '1' and column '2691': 'The template language expression 'formatDateTime(addDays(triggerBody()['estimatedclosedate'],7),'yyyy-MM-dd')' cannot be evaluated because property 'estimatedclosedate' cannot be selected. Please see https://aka.ms/logicexpressions for usage details.'.

    formatDateTime(addDays(triggerBody()?['estimatedclosedate'],7),'yyyy-MM-dd')


    Thanks!


    ------------------------------
    Julie Morris
    CRM Administrator
    Lockton Affinity
    Overland Park KS
    913-652-7688
    ------------------------------


  • 2.  RE: addDays Expression

    Posted Oct 29, 2019 02:06 PM
    I have it figured out. If anyone is wondering the correct expression is:

     estimatedclosedate gt formatDateTime(addDays(utcnow(),7),'yyyy-MM-ddTHH:mm:ssZ')


    ------------------------------
    Julie Morris
    CRM Administrator
    Lockton Affinity
    Overland Park KS
    913-652-7688
    ------------------------------