Setting: Customers reveice an email about a webinar offer. In that email, there is a buttnn that redirects to a CloudPagewith a Smart Capture form which they can fill out to attend the webinar.

The SmartCapture asks for First Name, Last Name, Email and Company. The value of the Customer Subscriber Key is passed from the email to the form using AmpScript.

The SmartCapture Form is used as an entry source for a journey that sends out a webinar confirmation email. All regristrants from that Smart Capture are stored in a Data Extensions which uses Subscriber Key and TimeStamp and Primary Key.

Problem: In case somebody fills out the form without a redirect from the email, the value of the subscriber key is not passed and the confirmation email won't be send.

idea: Create a default value (here: Email Address) for Subscriber Key in case no value of subscriber key is passed/or is unknown.

My AmpScript I inserted in Smart Capture field:

%%[var @Subscriber_Key, @Email
set @Email = "AttributeValue("Email")"
set @Subscriber_Key = "AttributeValue("Subscriber_Key")"


%%[IF Empty(@Subscriber_Key) OR @Subscriber_Key == "Unknown" THEN
 set @defaultvalue = @Email
 set @defaultvalue = @Subscriber_Key

However, this is not working. Can somebody help out?

<div class="smartcapture-controls">
    <div class="sc-formfield-label"><label for="Subscriber_Key"></label></div>
    <div class="sc-formfield-input"><input type="hidden" value=" %%=v(@defaultValue)=%%" name="Subscriber_Key" data-field-type="Text"></div>

1 Answer 1


Did you place the HTML code you shared inside the <form> created by your SmartCapture gear? I've successfully done that by editing the HTML of an arbitrary individual field on the SmartCapture form and inserting the hidden <input ..> tags there. Specifically:

  • In Layout view
  • Click a field in the preview of the SmartCapture form.
  • Click HTML Editor tab on the left
  • Insert your HTML there.

I can't speak to whether your AMPscript in the header is all correct, though.

You must log in to answer this question.

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