e.g.
Assign ttUserID = ttCallContextClient.CurrentUserID.
Assign ttDateXX = Today.
Within a BPM I am able to use the field "ttCallContextClient.CurrentUserID" to bring in information about the EPICOR user who is changing/updating a field. Does anyone happen to know what the analogous field is if I want to pull in the date that the field is being changed/updated?
I am using this for a customization to the customer table. Upon running the Customer.Update method I have information like the like the example below being sent to a UD table:
"PRICE LEVEL CHANGE | From: Customer.ShortChar01 | To: ttCustomer.ShortChar01 | By: ttCallContextClient.CurrentUserID | Date: ?????"
Complete Code for Anyone who is interested (just in case anyone finds it helpful):
/*Add source code that should be executed before the designed actions here*/
{&CALL_DESIGNED_ACTIONS}
/*Add source code that should be executed after the designed actions here*/
Define Var ttCustID as character no-undo.
Define Var ttShortChar01 as character no-undo.
Define Var ttShortChar02 as character no-undo.
Define Var ttShortChar03 as character no-undo.
Define Var ttShortChar04 as character no-undo.
Define Var ttShortChar05 as character no-undo.
Define Var ttCharacter01 as character no-undo.
Define Var ttCharacter02 as character no-undo.
Define Var ttCharacter03 as character no-undo.
Define Var ttCharacter04 as character no-undo.
Define Var ttCharacter05 as character no-undo.
Define Var ttCharacter06 as character no-undo.
Define Var ttCharacter07 as character no-undo.
Define Var ttNumber01 as decimal no-undo.
Define Var ttCheckBox01 as logical no-undo.
Define Var ttUserID as character no-undo.
Define Var ShortChar01ChangeRecord as character no-undo.
Define Var ShortChar02ChangeRecord as character no-undo.
Define Var ShortChar03ChangeRecord as character no-undo.
Define Var ShortChar04ChangeRecord as character no-undo.
Define Var Character01ChangeRecord as character no-undo.
Define Var Character02ChangeRecord as character no-undo.
Define Var Character03ChangeRecord as character no-undo.
Define Var Character04ChangeRecord as character no-undo.
Define Var Character05ChangeRecord as character no-undo.
Define Var Character06ChangeRecord as character no-undo.
Define Var Character07ChangeRecord as character no-undo.
Define Var Number01ChangeRecord as character no-undo.
Define Var CheckBox01ChangeRecord as character no-undo.
Assign ttCustID = ttCustomer.CustID.
Assign ttUserID = ttCallContextClient.CurrentUserID.
Assign ttShortChar01 = ttCustomer.ShortChar01.
Assign ttShortChar02 = ttCustomer.ShortChar02.
Assign ttShortChar03 = ttCustomer.ShortChar03.
Assign ttShortChar04 = ttCustomer.ShortChar04.
Assign ttCharacter01 = ttCustomer.Character01.
Assign ttCharacter02 = ttCustomer.Character02.
Assign ttCharacter03 = ttCustomer.Character03.
Assign ttCharacter04 = ttCustomer.Character04.
Assign ttCharacter05 = ttCustomer.Character05.
Assign ttCharacter06 = ttCustomer.Character06.
Assign ttCharacter07 = ttCustomer.Character07.
Assign ttNumber01 = ttCustomer.Number01.
Assign ttCheckBox01 = ttCustomer.CheckBox01.
For Each Customer where Customer.CustID = ttCustID,
Each UD21 where Customer.CustID = UD21.Key1:
IF ttShortChar01 <> Customer.ShortChar01 and Customer.ShortChar01 > "" then do:
Assign ShortChar01ChangeRecord = "PRICE LEVEL CHANGE | From: " + Customer.ShortChar01 + " | To: " + ttShortChar01 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar01 <> Customer.ShortChar01 and Customer.ShortChar01 = "" then do:
Assign ShortChar01ChangeRecord = "PRICE LEVEL SET | To: " + ttShortChar01 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar01 = Customer.ShortChar01 then do:
Assign ShortChar01ChangeRecord = "".
End.
IF ttShortChar02 <> Customer.ShortChar02 and Customer.ShortChar02 > "" then do:
Assign ShortChar02ChangeRecord = "FREIGHT TYPE CHANGE | From: " + Customer.ShortChar02 + " | To: " + ttShortChar02 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar02 <> Customer.ShortChar02 and Customer.ShortChar02 = "" then do:
Assign ShortChar02ChangeRecord = "FREIGHT TYPE SET | To: " + ttShortChar02 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar02 = Customer.ShortChar02 then do:
Assign ShortChar02ChangeRecord = "".
End.
IF ttShortChar03 <> Customer.ShortChar03 and Customer.ShortChar03 > "" then do:
Assign ShortChar03ChangeRecord = "FREIGHT TYPE UNDER LIMIT CHANGE | From: " + Customer.ShortChar03 + " | To: " + ttShortChar03 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar03 <> Customer.ShortChar03 and Customer.ShortChar03 = "" then do:
Assign ShortChar03ChangeRecord = "FREIGHT TYPE UNDER LIMIT SET | To: " + ttShortChar03 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar03 = Customer.ShortChar03 then do:
Assign ShortChar03ChangeRecord = "".
End.
IF ttShortChar04 <> Customer.ShortChar04 and Customer.ShortChar04 > "" then do:
Assign ShortChar04ChangeRecord = "TEMP DISTRO POWDER COAT CHANGE | From: " + Customer.ShortChar04 + " | To: " + ttShortChar04 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar01 <> Customer.ShortChar04 and Customer.ShortChar04 = "" then do:
Assign ShortChar04ChangeRecord = "TEMP DISTRO POWDER COAT SET | To: " + ttShortChar04 + " | By: " + ttUserID + "~n".
End.
IF ttShortChar04 = Customer.ShortChar04 then do:
Assign ShortChar04ChangeRecord = "".
End.
If ttCharacter01 <> Customer.Character01 then do:
Assign Character01ChangeRecord = "PRICE NOTES CHANGE" + "~n" + "| From: " + Customer.Character01 + "~n" + "| To: " + ttCharacter01 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter01 <> Customer.Character01 and Customer.Character01 = "" then do:
Assign Character01ChangeRecord = "PRICE NOTES SET" + "~n" + "| To: " + ttCharacter01 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter01 = Customer.Character01 then do:
Assign Character01ChangeRecord = "".
End.
If ttCharacter02 <> Customer.Character02 then do:
Assign Character02ChangeRecord = "FREIGHT NOTES CHANGE" + "~n" + "| From: " + Customer.Character02 + "~n" + "| To: " + ttCharacter02 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter02 <> Customer.Character02 and Customer.Character02 = "" then do:
Assign Character02ChangeRecord = "FREIGHT NOTES SET" + "~n" + "| To: " + ttCharacter02 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter02 = Customer.Character02 then do:
Assign Character02ChangeRecord = "".
End.
If ttCharacter03 <> Customer.Character03 then do:
Assign Character03ChangeRecord = "SALES NOTES CHANGE" + "~n" + "| From: " + Customer.Character03 + "~n" + "| To: " + ttCharacter03 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter03 <> Customer.Character03 and Customer.Character03 = "" then do:
Assign Character03ChangeRecord = "SALES NOTES SET" + "~n" + "| To: " + ttCharacter03 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter03 = Customer.Character03 then do:
Assign Character03ChangeRecord = "".
End.
If ttCharacter04 <> Customer.Character04 then do:
Assign Character04ChangeRecord = "CUSTOMER PRINT CHANGE" + "~n" + "| From: " + Customer.Character04 + "~n" + "| To: " + ttCharacter04 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter04 <> Customer.Character04 and Customer.Character04 = "" then do:
Assign Character04ChangeRecord = "CUSTOMER PRINT SET" + "~n" + "| To: " + ttCharacter04 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter04 = Customer.Character04 then do:
Assign Character04ChangeRecord = "".
End.
If ttCharacter05 <> Customer.Character05 then do:
Assign Character05ChangeRecord = "OTHER CABLE NOTES CHANGE" + "~n" + "| From: " + Customer.Character05 + "~n" + "| To: " + ttCharacter05 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter05 <> Customer.Character05 and Customer.Character05 = "" then do:
Assign Character05ChangeRecord = "OTHER CABLE NOTES SET" + "~n" + "| To: " + ttCharacter05 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter05 = Customer.Character05 then do:
Assign Character05ChangeRecord = "".
End.
If ttCharacter06 <> Customer.Character06 then do:
Assign Character06ChangeRecord = "TEMP DISTRO CUSTOM POWDER COAT CHANGE | From: " + Customer.Character06 + " | To: " + ttCharacter06 + " | By: " + ttUserID + "~n".
End.
IF ttCharacter06 <> Customer.Character06 and Customer.Character06 = "" then do:
Assign Character06ChangeRecord = "TEMP DISTRO CUSTOM POWDER COAT SET | To: " + ttCharacter06 + " | By: " + ttUserID + "~n".
End.
IF ttCharacter06 = Customer.Character06 then do:
Assign Character06ChangeRecord = "".
End.
If ttCharacter07 <> Customer.Character07 then do:
Assign Character07ChangeRecord = "OTHER DISTRO NOTES CHANGE" + "~n" + "| From: " + Customer.Character07 + "~n" + "| To: " + ttCharacter07 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter07 <> Customer.Character07 and Customer.Character07 = "" then do:
Assign Character07ChangeRecord = "OTHER DISTRO NOTES SET" + "~n" + "| To: " + ttCharacter07 + "~n" + "| By: " + ttUserID + "~n".
End.
IF ttCharacter07 = Customer.Character07 then do:
Assign Character07ChangeRecord = "".
End.
If ttNumber01 <> Customer.Number01 then do:
Assign Number01ChangeRecord = "FREIGHT ALLOWED OVER VALUE CHANGE | From: " + string(Customer.Number01) + " | To: " + string(ttNumber01) + " | By: " + ttUserID + "~n".
End.
IF ttNumber01 <> Customer.Number01 and Customer.Number01 = 0 then do:
Assign Number01ChangeRecord = "FREIGHT ALLOWED OVER VALUE SET | To: " + string(ttNumber01) + " | By: " + ttUserID + "~n".
End.
IF ttNumber01 = Customer.Number01 then do:
Assign Number01ChangeRecord = "".
End.
/*Pricing Information*/
If ShortChar01ChangeRecord > "" or Character01ChangeRecord > "" then do:
Assign UD21.Character01 = UD21.Character01 + ShortChar01ChangeRecord + Character01ChangeRecord.
End.
/*Sales Information*/
If Character03ChangeRecord > "" then do:
Assign UD21.Character02 = UD21.Character02 + Character03ChangeRecord.
End.
/*Cable Information*/
If Character04ChangeRecord > "" or Character05ChangeRecord > "" then do:
Assign UD21.Character03 = UD21.Character03 + Character04ChangeRecord + Character05ChangeRecord.
End.
/*Freight Information*/
If ShortChar02ChangeRecord > "" or Number01ChangeRecord > "" or ShortChar03ChangeRecord > "" or Character02ChangeRecord > "" then do:
Assign UD21.Character04 = UD21.Character04 + ShortChar02ChangeRecord + Number01ChangeRecord + ShortChar03ChangeRecord + Character02ChangeRecord.
End.
/*Distro Information*/
If Character06ChangeRecord > "" or Character07ChangeRecord > "" then do:
Assign UD21.Character05 = UD21.Character05 + Character06ChangeRecord + Character07ChangeRecord.
End.
If (ShortChar01ChangeRecord > "" or ShortChar02ChangeRecord > "" or ShortChar03ChangeRecord > "" or ShortChar04ChangeRecord > "" or Character01ChangeRecord > "" or Character02ChangeRecord > "" or
Character03ChangeRecord > "" or Character04ChangeRecord > "" or Character05ChangeRecord > "" or Character06ChangeRecord > "" or Character07ChangeRecord > "" or Number01ChangeRecord > "") then do:
Assign UD21.Character09 = UD21.Character09 + ShortChar01ChangeRecord + Character01ChangeRecord + Character03ChangeRecord + Character04ChangeRecord + Character05ChangeRecord + ShortChar02ChangeRecord + Number01ChangeRecord + ShortChar03ChangeRecord + Character02ChangeRecord + ShortChar04ChangeRecord + Character06ChangeRecord + Character07ChangeRecord.
Assign UD21.Character10 = UD21.Character10 + ShortChar01ChangeRecord + Character01ChangeRecord + Character03ChangeRecord + Character04ChangeRecord + Character05ChangeRecord + ShortChar02ChangeRecord + Number01ChangeRecord + ShortChar03ChangeRecord + Character02ChangeRecord + ShortChar04ChangeRecord + Character06ChangeRecord + Character07ChangeRecord.
End.
If ttCheckBox01 = TRUE then do:
Assign UD21.Character10 = "".
Assign UD21.Character10 = "LAST REVIEWED & APPROVED | By: " + ttUserID + "~n".
Assign UD21.Character01 = UD21.Character01 + "REVIEWED & APPROVED | By: " + ttUserID + "~n".
Assign UD21.Character02 = UD21.Character02 + "REVIEWED & APPROVED | By: " + ttUserID + "~n".
Assign UD21.Character03 = UD21.Character03 + "REVIEWED & APPROVED | By: " + ttUserID + "~n".
Assign UD21.Character04 = UD21.Character04 + "REVIEWED & APPROVED | By: " + ttUserID + "~n".
Assign UD21.Character05 = UD21.Character05 + "REVIEWED & APPROVED | By: " + ttUserID + "~n".
End.
End.