Prevent date field from changing format on data entry

5hadow

Member
Local time
Today, 10:24
Joined
Apr 26, 2021
Messages
89
I have a date and time fields which displays what I want it to display. I've also set up an input mask for users to enter what I need them to enter.
It looks like:
1653362915678.png

However, when I try to edit the field it changes the format.
When clicking on date field:
1653362979522.png

When clicking on time field:
1653363004784.png


How do I prevent this behavior?
It's confusing for some users because if you do make a change, it doesn't work with input mask and I get an error.
 
I have a date and time fields which displays what I want it to display. I've also set up an input mask for users to enter what I need them to enter.
[...]
It's confusing for some users because if you do make a change, it doesn't work with input mask and I get an error.
Maybe your users would be less confused if you don't display the data the way you want it to be displayed but the way they want it displayed.

Except for reports that get distributed to other people, I don't see any reason to display the dates differently than the user wants to see them.
 
what is being Displayed (without you clicking it first), is the way you Format you date/time.
when you clicked on it, it now display what you define on your Locale setting.

to prevent this set the locale and your format date the same.
but if others are using your db, that is the problem.
i don't know if you can convinced them to change their computers locale settings.
 
what is being Displayed (without you clicking it first), is the way you Format you date/time.
when you clicked on it, it now display what you define on your Locale setting.

to prevent this set the locale and your format date the same.
but if others are using your db, that is the problem.
i don't know if you can convinced them to change their computers locale settings.
Ok, that's what I thought. I knew it was something to do with local time. Thanks!
 
How do I prevent this behavior?
I did so:
I copied the date (time) value from hidden field into an unrelated text field on the Form_OnCurrent event, checked for IsDate() or IsTime() after editing, and then copied back ...
 

Users who are viewing this thread

Back
Top Bottom