Brilliant, been looking for that.
________________________________
From: bw2868bond <bwalker@...>
To: vantage@yahoogroups.com
Sent: Wed, 4 November, 2009 19:26:21
Subject: [Vantage] Re: BPM - 4GL for sending an email
Â
An Example:
for each ttinventoryqtyadj no-lock.
find PartCost where PartCost.Company = ttinventoryqtyadj. Company and PartCost.PartNum = ttinventoryqtyadj. PartNum and PartCost.CostID = '1' no-lock.
if ABSOLUTE(ttinventor yqtyadj.AdjustQu antity * PartCost.StdMateria lCost) > 1000 then do:
repeat:
define variable mFrom as character no-undo initial 'xyz@mycompany. com':U.
define variable mTo as character no-undo initial 'abc@mycompany. com':U.
define variable mCc as character no-undo initial 'def@mycompany. com':U.
define variable mSubject as character no-undo initial 'Inv Adjust Variance Value Exceeded':U.
define variable mBody as character no-undo initial '':U.
define variable mhEmailProc as handle no-undo.
run Bpm/BpmEmail. p persistent set mhEmailProc.
assign mBody = mBody + 'Part Number ' + string(ttinventoryq tyadj.PartNum) .
assign mBody = mBody + ' ' + ttinventoryqtyadj. PartPartDescript ion.
assign mBody = mBody + '~n'.
assign mBody = mBody + 'Adjusted by ' + string(DCD-USERID) .
assign mBody = mBody + '~n'.
assign mBody = mBody + ' has a variance value of $' + string((ttinventory qtyadj.AdjustQua ntity * PartCost.StdMateria lCost),"> >>,>>>,>> 9.99").
run SendEmail in mhEmailProc (
false,
CUR-COMP,
mFrom,
mTo,
mCc,
mSubject,
mBody,
"":U
).
if valid-handle( mhEmailProc) then delete procedure mhEmailProc.
leave.
end.
end.
end.
________________________________
From: bw2868bond <bwalker@...>
To: vantage@yahoogroups.com
Sent: Wed, 4 November, 2009 19:26:21
Subject: [Vantage] Re: BPM - 4GL for sending an email
Â
An Example:
for each ttinventoryqtyadj no-lock.
find PartCost where PartCost.Company = ttinventoryqtyadj. Company and PartCost.PartNum = ttinventoryqtyadj. PartNum and PartCost.CostID = '1' no-lock.
if ABSOLUTE(ttinventor yqtyadj.AdjustQu antity * PartCost.StdMateria lCost) > 1000 then do:
repeat:
define variable mFrom as character no-undo initial 'xyz@mycompany. com':U.
define variable mTo as character no-undo initial 'abc@mycompany. com':U.
define variable mCc as character no-undo initial 'def@mycompany. com':U.
define variable mSubject as character no-undo initial 'Inv Adjust Variance Value Exceeded':U.
define variable mBody as character no-undo initial '':U.
define variable mhEmailProc as handle no-undo.
run Bpm/BpmEmail. p persistent set mhEmailProc.
assign mBody = mBody + 'Part Number ' + string(ttinventoryq tyadj.PartNum) .
assign mBody = mBody + ' ' + ttinventoryqtyadj. PartPartDescript ion.
assign mBody = mBody + '~n'.
assign mBody = mBody + 'Adjusted by ' + string(DCD-USERID) .
assign mBody = mBody + '~n'.
assign mBody = mBody + ' has a variance value of $' + string((ttinventory qtyadj.AdjustQua ntity * PartCost.StdMateria lCost),"> >>,>>>,>> 9.99").
run SendEmail in mhEmailProc (
false,
CUR-COMP,
mFrom,
mTo,
mCc,
mSubject,
mBody,
"":U
).
if valid-handle( mhEmailProc) then delete procedure mhEmailProc.
leave.
end.
end.
end.
--- In vantage@yahoogroups .com, melissa hietala <kevmel822@. ..> wrote:
>
> Does anyone know if it possible in a BPM to send an e-mail utilizing 4GL code? And if so, does anyone have an example of code that can be used to accomplish this?
>
> Thank you,
>
> Dustin Biniek
>
>
>
>
> [Non-text portions of this message have been removed]
>
[Non-text portions of this message have been removed]