尝试链接数据,然后使用Ampscript显示不同的内容块

发布于 2025-02-04 18:42:11 字数 347 浏览 2 评论 0原文

我试图从另一个(共享)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 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

瑶笙 2025-02-11 18:42:11

您的代码块不会显示实际的内容块。它仅根据数据行上的“查找”函数“设置”内容块。
您需要添加%% = 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)=%%

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文