Announcement

Collapse
No announcement yet.

Formula Not working after save

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Formula Not working after save

    Hi All,

    I have a frustrating situation here.

    So I added a formula in my opportunity entity, to copy the name of the originalLeadName into the opportunity name, this is the formula code i've used:

    name=originalLeadName;
    The problem is when i tried to convert a lead into opportunity, it does not change the name, however when I tried to recalculate formula, the name changed.

    So at the moment i have to recalculate formula every day.

    Is there any input on what should i do to make this work without have to recalculate formula all the time.


    Thanks

  • #2
    Hi ivan2805,

    You can do this automatic update through Workflow (a feature from the Advanced Pack extension).

    Create a Workflow with the following parameters:

    Target Entity > Lead
    Trigger Type > After record updated

    Conditions > All (All must be met) >Status equals value > Converted

    Actions:
    Update Related Record ยป Opportunity
    Formula: name = originalLeadName;
    Last edited by lazovic; 08-11-2022, 10:27 AM.

    Comment


    • #3
      Hi lazovic

      So it means i can not achieve this using formula?

      Is there work around since i don't have advance pack yet.

      Thank you for your kind answer

      Comment


      • #4
        It's a before-save-script (as it labeled on UI). The originalLeadName is not yet available before the record is saved.

        Comment


        • #5
          Originally posted by ivan2805 View Post
          Hi All,

          I have a frustrating situation here.

          So I added a formula in my opportunity entity, to copy the name of the originalLeadName into the opportunity name, this is the formula code i've used:



          The problem is when i tried to convert a lead into opportunity, it does not change the name, however when I tried to recalculate formula, the name changed.

          So at the moment i have to recalculate formula every day.

          Is there any input on what should i do to make this work without have to recalculate formula all the time.


          Thanks
          you can reverse the formula and use it on the lead instead so when the lead is converted into an opportunity you can then update opportunity name to be equal to the lead's name, try formula below on the lead:

          Code:
          ifThen(entity\isAttributeChanged('status') && entity\attribute('status') == "Converted" && entity\attribute('createdOpportunityId'),
          record\update('Opportunity', createdOpportunityId, 'name', entity\attribute('name'))
          )

          Comment


          • #6
            Thank you rabii as always your a life saver

            Comment

            Working...
            X