LightningChart logic hangs UI on virual machine

A forum dedicated to WinForms version of LightningChart Ultimate.

Moderator: Arction_LasseP

ArtemK
Posts: 1
Joined: Wed Apr 07, 2021 9:06 am

LightningChart logic hangs UI on virual machine

Post by ArtemK » Wed Apr 07, 2021 9:35 am

Hello,
I have a problem with the application UI freezing when drawing LightningChart control.
It is a WPF application but a chart of Windows Forms controls.
This problem is reproducible only on a virtual machine. At the moment of hangning, the debug shows that several streams of the LightningChart are currently working.
The existing information is vague, but is there any suspicion of a possible problem. Any additional information I could provide?
Attachments
image_2021_04_07T08_45_11_823Z.png
image_2021_04_07T08_45_11_823Z.png (92.55 KiB) Viewed 139 times

ArctionKestutis
Posts: 405
Joined: Mon Mar 14, 2016 9:22 am

Re: LightningChart logic hangs UI on virual machine

Post by ArctionKestutis » Thu Apr 08, 2021 6:35 am

There is nothing special about virtual machine, which should prevent LightingChart running on it. Unless machine configured not to use accelerated GPU, low on memory or have no DirectX (at least 9.0c) support.
Your image suggest that you may have thread problem. Please make sure that all Chart’s properties updated in the Main UI Thread. LightningChart requires that all the Chart properties should be updated in Main UI Thread. LightningChart should be updated in the Main Thread, as for the most UI controls. When using a background thread in the application, all UI updates from the thread must go through Invoke (Control.Invoke() in WinForms, and Dispatcher.Invoke() in WPF). If chart is not updated in Main Thread user may get very random and unexpected results (including crashes and access violation).

Hope this helps.