Skip to main content
Known Participant
February 1, 2018
Question

format field with upper case character

  • February 1, 2018
  • 1 reply
  • 700 views

I have a text field that I need users to enter a specific number format in. The field format must look like A99999. The first character must be upper case character. I will appreciate for detail explanation how to do it in Acrobar DC?

This topic has been closed for replies.

1 reply

try67
Community Expert
Community Expert
February 1, 2018

You will need to write a custom Format keystroke or validation script.

eugzlAuthor
Known Participant
February 2, 2018

Hi try67. Thanks for replay.

I have code in validation script:

event.change = event.change.toUpperCase();

It works. But when I specified format entered data like: A99999 I lost upper case. How to have forth upper case first character and format enterd data?

Thanks.

try67
Community Expert
Community Expert
February 2, 2018

The question is do you want to prevent the user from entering text that doesn't follow this pattern, or do you want to let them enter anything, but reject it if it's incorrect. For the former you would need a Keystroke script. For the latter a Validation script will do.