Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Date field to only accept numbers

Avatar

Avatar
Validate 1
Level 1
Yvette_s_Channe
Level 1

Likes

0 likes

Total Posts

29 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
Yvette_s_Channe
Level 1

Likes

0 likes

Total Posts

29 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile
Yvette_s_Channe
Level 1

09-05-2017

I am creating a LiveCycle form and I want the date field/numeric field to only accept number. I do not want the user to be able to type in special characters or letter. I want the format to be MM/DD/YYYY but no alpha or special characters. Is there a way to do that?

Thanks in advance,

Ife

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Coach
MVP
radzmar
MVP

Likes

394 likes

Total Posts

2,686 posts

Correct Reply

490 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile

Avatar
Coach
MVP
radzmar
MVP

Likes

394 likes

Total Posts

2,686 posts

Correct Reply

490 solutions
Top badges earned
Coach
Ignite 3
Ignite 1
Validate 1
Give Back 50
View profile
radzmar
MVP

09-05-2017

To restrict the characters a user can enter to 0-9 use this script in the fields change event.

if (!xfa.event.change.match(/[0-9]|/)) {

  xfa.event.change = "";

}

Answers (1)

Answers (1)

Avatar

Avatar
Validate 1
Level 1
Yvette_s_Channe
Level 1

Likes

0 likes

Total Posts

29 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
Yvette_s_Channe
Level 1

Likes

0 likes

Total Posts

29 posts

Correct Reply

0 solutions
Top badges earned
Validate 1
View profile
Yvette_s_Channe
Level 1

15-05-2017

Thank you!