3

I've figured out how to create forms with discount codes in Cognito Forms. I'd like to be able to prevent specific discount codes from being entered more than once. For example, suppose I will deem a discount code 'valid' if it contains the text 'ABC.' I can check for that, easily. So codes ABC123, ABC456, ABC789, etc. would all be valid. But what if I want to ensure that ABC123 only gets entered once total among all form entries, ABC456 only gets entered once among all form entries, etc. Is this possible? I do not want to limit respondents to how many forms they are allowed to submit.

1 Answer 1

2

You can easily limit the number of times a value is submitted in Cognito Forms by enabling quantity limits on your form. In the case of single use discount codes, you would do the following:

  1. Select your Discount Code field in the builder
  2. Set Limit Quantity to No Duplicates
  3. Set Error Message to This discount code has already been used!

This will prevent discount codes from being used more than once!

enter image description here

You can learn more about quantity limits in our help documentation!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.