Developer forum

Forum » Development » Cancel email marketing send for specific user

Cancel email marketing send for specific user

Jonas Mersholm
Reply

Hi,

How would i cancel an email marketing newsletter for a user if a specific conditional is not met? 

Etc. The page to send as an email is rendered per. recipient, and i would like to check wether or not the user meets some requirements before proceeding. If they match, the email will be send, if not, it wont send.

Is this possible from the Template? I've checked the few notifications for the emailmarketing API, but none of them seems to have any properties to cancel the email.

 

Best,

Jonas 


Replies

 
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi Jonas

You have to do that from the smartsearch of the user.

An alternative is to listen to the Dynamicweb.EmailMarketing.Notifications.OnAfterPreprocessing notification - its argument has a message object which is the one being sent.

You might be able to manipulate that message so nothing gets send... No guarantees...

BR Nicolai

Votes for this answer: 1

 

You must be logged in to post in the forum