on 06-07-2013 11:55 PM
Hi Everybody
I'm investigating about how to send notifications mails after an operation, I found a BO named "EmailActivity", apply the example code but I don't understand where it takes the mail I don't have errors in the syntaxis, but in the moment of run the code shows this message:
import ABSL;
import AP.FO.Activity.Global;
//EmailActivity: Root node
var elEmailRoot : elementsof EmailActivity;
var instEmail;
// EmailActivity: define party node
var elEmailParty : elementsof EmailActivity.Party;
var instParty;
// EmailActivity: define service order text collection
var TXT_TYPE_BODY_TEXT = "10002";
var elEmailTxtCollTxt: elementsof EmailActivity.TextCollection.Text;
var elEmailTxtCollTxtCntnt: elementsof EmailActivity.TextCollection.Text.TextContent;
var instEmailTxtColl;
var instEmailTxtCollTxt;
// EmailActivity: maintain description - mandatory
elEmailRoot.Name.content = "PSM CRM ABSL Test - CallEmailExample Example_01";
// EmailActivity: create new instance
instEmail = EmailActivity.Create(elEmailRoot);
// Email: Organizer party - mandatory
if (! instEmail.MessageFromParty.IsSet()) {
elEmailParty.PartyKey.PartyID.content = "00163E0312B41EE2B3A85F4B8DB6EEFE";
//elEmailParty.AddressReference.AddressHostUUID.content
instEmail.MessageFromParty.Create(elEmailParty);
}
// Email: Set Employee Responsible mandatory
if (! instEmail.EmployeeResponsibleParty.IsSet()) {
elEmailParty.PartyKey.PartyID.content = "00163E0312B41EE2B3DA1D0FADD9E7FB"; // Set Employee ID
instEmail.EmployeeResponsibleParty.Create(elEmailParty);
}
// Create a text of type "Body Text"
instEmailTxtColl = instEmail.TextCollection.Create();
elEmailTxtCollTxt.TypeCode.content = TXT_TYPE_BODY_TEXT;
instEmailTxtCollTxt = instEmailTxtColl.Text.Create(elEmailTxtCollTxt);
elEmailTxtCollTxtCntnt.Text.content = "Texto del e-mail";
instEmailTxtCollTxt.TextContent.Create(elEmailTxtCollTxtCntnt);
How to send automatically notification email?
The instances of the EmailActivity business object that were successfully saved, can be found in work center "Account Management" -> View "Activities".
Best regards,
Kornelia
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.