Creation of 42 character exact Custom Field | Community
Skip to main content
New Participant
February 8, 2021
Question

Creation of 42 character exact Custom Field

  • February 8, 2021
  • 2 replies
  • 1685 views

I was wondering if anybody knows of a way to create a string custom field but with limitations on the amount of characters to be 42. So when the person fills out the field they cannot enter less than or greater than 42 characters, it has to be exactly 42?

 

If one does not exist, does anybody know of a workaround that would accomplish the same task?

 

Thanks!

 

AH

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

2 replies

SanfordWhiteman
New Participant
February 9, 2021

I was wondering if anybody knows of a way to create a string custom field but with limitations on the amount of characters to be 42. So when the person fills out the field they cannot enter less than or greater than 42 characters, it has to be exactly 42?

Yes — assuming you're talking about the field on a form (not updating the field via the Marketo UI, or any other method). And it doesn't even take any JS!

 

Use a Pattern Mask:

 

 

 

 

Veronica_Holme4
New Participant
February 8, 2021

If what you mean by "when a person fills out the field" is through a Marketo form, that's where you will need to put the validation. You cannot put this validation on the custom field in Marketo itself. There's plenty of ways to build custom form validation through javascript.