Monday, January 14, 2013

Invient Charts, Problem with TimeZone - always in UTC

The Problem


It seemed that all my InvientChart 0.8.6 charts in Vaadin were two hours behind where they should have been. And because I live in GMT + 2 it seemed like a timezone issue.

The solution


Before adding your chart to the UI add this component


            try {
                CustomLayout cl = new CustomLayout(new ByteArrayInputStream("
".getBytes())); addComponent(cl); } catch (IOException ex) { //should never happen log.warn("Should never happen",ex); }

No comments:

Post a Comment