01-19-2021 09:28 AM
This happened to me all of a sudden. I am not able to enter a time in a numeric control. see attached.
When I enter a time it just defaults back to 0
Any help would be appreciated
Thanks
Solved! Go to Solution.
01-19-2021 09:36 AM
Works fine for me. I wrapped a loop around your control and connected an indicator to check it. No problem.
Did you change any attributes? Coerce maybe??? Right-click it and check...
01-19-2021 09:43 AM
What time are you entering? It seems to work fine for me.
01-19-2021 10:02 AM
01-19-2021 10:03 AM
01-19-2021 11:28 AM
You have some weird data entry limits set (Max=Min). Does it work better if you go back to defaults?
01-19-2021 02:01 PM
01-19-2021 02:06 PM
01-19-2021 03:38 PM - edited 01-19-2021 03:44 PM
Remember that the time stamp control is not just for time, but for time/date. So even though you might enter something like 3:00 pm, that is 3:00 pm on a particular date that is not shown with your display settings. If I show the date and enter 3:00pm it is 3 pm on 12/31/1903.
Which time zone are you in? Are you eastern? I found the same issue. And 7 pm would be a special time/date in the eastern timezone because 7pm 12/31/1903 is time 0 which is midnight UTC for 1/1/1904, the epoch of the LabVIEW time system.
I also think I remember some issues, (bugs?) in LabVIEW related to entering some times at the epoch.
Remember, you can also set a double numeric control or indicator to display a value in the format of time. I think that may be a better way to handle a time that you don't want to have a date associated with it like here where "Time to Read" file means, hey I want to read it 7pm every day. You've got to do the code to handle it, but you've got to deal with it also with a timestamp control to distinguish between 7pm yesterday, 7 pm today, 7 pm tomorrow, and 7pm on 12/31/1903.
EDIT: I did a little searching to see if I could find a thread that I think exists suggesting a bug. Haven't found that, but found this https://stackoverflow.com/questions/15106210/incorrect-timestamp-control-value which talks about the special case of 0 for a timestamp. Basically a hard 0 is a special time that LabVIEW displays like an empty timestamp display rather than the data that is associated with 0, the epoch of midnight 1/1/1904 GMT.
01-20-2021 08:59 AM - edited 01-20-2021 08:59 AM