Workflow on sales order price change

SUGGESTED

I am trying to create a workflow to trigger when the net price on a sales order line has been changed. I would like the workflow email to contain both the value before the change and the value after. I am close, but seem to not be able to capture the correct line. If there are 3 lines on the sales order, I get 3 emails when I only want 2 email with the information from the line which the price was changed. 

Here is my workflow and data model. Any suggestions? 

Parents
  • 0

    Hi Bolta_TJ,

    I was wondering if you ever got this workflow to work.  I am trying to create a similar workflow but with the SO Delivery date field but having different issues.  Seems to display a workflow even if the date wasn't changed and then it is dsiplaying the changed date as the first date entered originally.  I'm wondering if this is even possible now.

    If you have any feedback would greatly appreciate.

    Thanks!

    Christine

  • 0 in reply to Christine T.
    SUGGESTED

    #You would have to write a function like this a nd call it as below and save it in a file YFUNCS

    #The message part is as below:

    ####################################################################

    Order |[F:SOH]SOHNUM | has been updated by |GUSER| Date and Time |Datetime$|

    |FUNC YFUNCS.PRICE_CHANGES()|

    #########################################################

    #The function is as below

    Funprog PRICE_CHANGES()
    Local Char ALL_CHANGES(250)

    ALL_CHANGES='Price Changes: ' +chr$(13) + chr$(10)
    For [F:SOP] Where SOHNUM=[M:SOH0]SOHNUM
    ALL_CHANGES += num$(SOPLIN/1000)+': '+ num$([F:SOP]NETPRI) +' TO '+ num$([M:SOH4]NETPRI(SOPLIN/1000))+chr$(13) + chr$(10)
    Next
    End ALL_CHANGES

    #For more help email [email protected]

  • 0 in reply to ardzimano

    thanks for reply but I don't understand where would this code be placed?

Reply Children