尝试链接数据,然后使用Ampscript显示不同的内容块
我试图从另一个(共享)DE中引入数据,然后使用IF语句根据结果显示特定的内容块。我设法摆脱了错误,但没有显示内容块。我要去哪里?
SET @CustomerContactable = Lookup ('ENT.Customerdata', 'CustomerContactable', 'Id', @SubscriberKey)
IF @CustomerContactable == 'True' THEN SET @BodyContent = ContentBlockbyId("127410") ELSE
SET @BodyContent = ContentBlockbyId("127411") ENDIF]%%```
I'm trying to bring in data from another (shared) DE and then using IF statement to show a specific content block depending on the outcome. I have managed to get rid of the errors but no content block is showing. Where am I going wrong?
SET @CustomerContactable = Lookup ('ENT.Customerdata', 'CustomerContactable', 'Id', @SubscriberKey)
IF @CustomerContactable == 'True' THEN SET @BodyContent = ContentBlockbyId("127410") ELSE
SET @BodyContent = ContentBlockbyId("127411") ENDIF]%%```
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您的代码块不会显示实际的内容块。它仅根据数据行上的“查找”函数“设置”内容块。
您需要添加
%% = TreataScontent(@bodyContent)= %%
Your code block doesn't display the actual content block. It only "sets" the content block based upon your "LookUp" function, on the data row.
You would need to add
%%=TreatAsContent(@BodyContent)=%%