Quantcast
Channel: Active questions tagged ampscript - Salesforce Stack Exchange
Viewing all articles
Browse latest Browse all 359

Display no content if the condition is not met AMP script

$
0
0

I'm trying to build a dynamic email with different blocks displaying based on the if/else check. I can't understand how do I display nothing and go to the next step if the condition is not met.Here is the code:

var @conditionSet @condition= AttributeValue("Value")set @content = ContentBlockById("123456")IF IndexOf(@condition, "value1")>0 OR IndexOf(@condition, "value2")>0 THENset @block1 = @contentELSE set @block1 = **here I need to display nothing**ENDIF]%%%%=v(@block1)=%%

Is there any specific string for it?

Thanks!


Viewing all articles
Browse latest Browse all 359

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>