Customer Macro Help - Lead Scoring Contact Groups

SHANE EBERT asked on May 4, 2017 15:38

Hello,

I am looking to create a custom macro for lead scoring purposes. I want to assign the score of 5 to every contact in a contact group that has the word "Attendee" in the group name. If they are in 5 contact groups with the word "Attendee" I want them to recieve a score of 25.

Currently, I am able to do this, if I create a separate rule for each contact group. The problem is, there are MANY of these groups and new ones are created every week.

I am wondering if there is some code that can accomplish this without me creating a rule for EVERY group.

Below is the current macro I am using, but like I said, every group I have to create a separate rule.

(Contact.IsInContactGroup("IllinoisNOTEApr262017AttendeesWLK", false))

Thanks for any help!

Correct Answer

Trevor Fayas answered on May 5, 2017 15:23

Hi Shane,

This would give you the # of attendees (multiplied by 5) {% OnlineMarketingContext.CurrentContact.ContactGroups.Where("ContactGroupName.contains(\"Attendees\")").Count*5 %}

However i don't see a way to dynamically set the "Score" in a rule currently. So you may need to create 5 separate rules with 5 points each.

0 votesVote for this answer Unmark Correct answer

   Please, sign in to be able to submit a new answer.