Hi,
I have been able to make lots of e-mails in CRM 1.2.
For the life of me, I cannot seem to figure out how to get them to work in
3.0. Here is my code:
activityparty[] activitypartyFrom;
activitypartyFrom[0].addressused = HDEmailAddress;
activitypartyFrom[0].partyid.name = HDGuid;
activitypartyFrom[0].participationtypemask.Value = 1;
activityparty[] activitypartyTo;
activitypartyTo[0].addressused = HDEmailAddress;
activitypartyTo[0].partyid.name = HDGuid;
activitypartyTo[0].participationtypemask.Value = 2;
email.to = activitypartyTo;
email.from = activitypartyFrom;
email.subject = "This is a test";
This code will not even compile properly.
I have also tried this:
activityparty activitypartyFrom;
activitypartyFrom.addressused = HDEmailAddress;
activitypartyFrom.partyid.name = HDGuid;
activitypartyFrom.participationtypemask.Value = 1;
activityparty activitypartyTo;
activitypartyTo.addressused = HDEmailAddress;
activitypartyTo.partyid.name = HDGuid;
activitypartyTo.participationtypemask.Value = 2;
email.to = activitypartyTo;
email.from = activitypartyFrom;
email.subject = "This is a test";
AND I have tried this:
activityparty activitypartyFrom = new activityparty();
activitypartyFrom.addressused = HDEmailAddress;
activitypartyFrom.partyid.name = HDGuid;
activitypartyFrom.participationtypemask.Value = 1;
activityparty activitypartyTo = new activityparty();
activitypartyTo.addressused = HDEmailAddress;
activitypartyTo.partyid.name = HDGuid;
activitypartyTo.participationtypemask.Value = 2;
email.to = activitypartyTo;
email.from = activitypartyFrom;
email.subject = "This is a test";
I am getting conversion issues of arraylists and activityparty types. I
understand this error, but cannot seem to figure out how to resolve it. Can
someone post me an example code of how to create and send an e-mail
programmatically in CRM v3.0.
Regards,
Keener