I created an email with a CloudPage button link. We will have different emails leading to this cloudpage which contains a smartcapture form, but I want to track which email drove the subscriber to the smartcapture form.

I thought adding a constant AMPscript variable to the email would allow me to ID that email and pass the constant variable to the hidden smartcapture field. But, that value is not carrying over. However, all the target DE fields for the subscriber are pre-populating just fine on the form (i.e. first name, Last Name, Email). Here's What I've set in the email:

var @EntrySource
set @EntrySource = "Email 1"

And here is what i placed in the smart form field value:


Is it not possible to carry these constant variables to cloudpage form fields when setting a link destination to a cloudpage?


1 Answer 1


%%=v(@EntrySource)%%has to be %%=v(@EntrySource)=%%you were missing the = character. Another thing. Smart forms are bad for a lot of different reasons, one of them is interaction with ampscript therefore and a lot of developers in this forum will advice you to write it on your own with usual web techniques.

For subscriber interaction you should use the CloudPagesURL function. There are a lot of parameters included in the hashed qs parameter that you can use to then use lookup functions. Example are subscriberid or subscriberkey (generally a lot of the personalization variables generated by salesforce).

If you want to pass a static parameter you could also give the cloudpagesurl some extra parameters which you then can request via ampscript.

  • Thank you @Johannes! I failed to realize I can simply set those constant parameters and values in the CloudpageURL function, and not in the email itself. Jun 3, 2020 at 17:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .