Time discrepancy in view vs property

Having an issue with time zones. Gateway OS is set to UTC, but I want client to be set to CST. I've set timeZoneId = CST. When I place a label on a view with an expression binding of "now()", the property will display the correct time with time zone offset. But the actual label on the view will still display with UTC as default. For example the text property will say "9:34" which matches my PC time, but the label will say "14:35".

Dates in Ignition are objects containing UTC milliseconds, no matter the time zone. When you ask for an object to be assigned to a text property, Java will stringify it right there, which is in the gateway for expressions. Java default stringification of dates uses the JVM timezone, which is UTC in your case.

The designer is a separate JVM, and it will stringify locally for you. Perspective browsers will not, unless you trigger native timezone handling (not available in a label).

See this topic for options:

1 Like

Awesome that worked great thank you so much