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
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Date time field problem

SnookerDJ
Level 4
Level 4
Hello there



This maybe a simple problem but on the Date time field object i have input a display pattern and put the error message in. When I preview the PDF and populate the object with random text the pop up box will display my error message.



What it does not do is clear the text I have input so the date can be re-entered correctly, which is what I was expecting. Therefore the user can continue on without addressing the date correctly.



Can anyone advise what I should do to get this to work?



Thanks



Darren
1 Reply
SnookerDJ
Level 4
Level 4
Hi



The first time I thinkanyone has answered their own post. So for the benefit of anyone else I added the folowing script to the exit event

of the date field object



if (page.subform.dateobject.rawValue == page.subform.dateobject.formattedValue) {



xfa.host.resetData("xfa.form.Formtitle.Page.subform.datefieldobject")



Not sure why it works but just played around with it.