There is some way how to synchronize a viewport control with several winchartviewers, that is, use the same controller for several winchartviewers. I'm runing in C# and using the chardirecot .net.
Re: synchronize a viewport control with several winchartviewers
Yes. You can use the same ViewPortChanged event handler to update all the charts in all the WinChartViewers.
Suppose you have two WinChartViewers, called "winChartViewer1" and "winChartViewer2". You can set up a WinViewPortControl and connect it to "winChartViewer1". Then in the ViewPortChanged event handler, you can update both charts in both WinChartViewers. It is like:
void winChartViewer1_ViewPortChanged(object sender, WinViewPortEventArgs e)
// Update the chart if necessary
// update chart 1
Would you also allow the user to zoom/scroll without using the WinViewPortControl? For example, can the user zoom by using the mouse wheel over winChartViewer2? If the user can do this, then you would need to handle the ViewPortChanged event for winChartViewer2 by forwarding that event to winChartViewer1. It is like:
void winChartViewer2_ViewPortChanged(object sender, WinViewPortEventArgs e)
// forward event to winChartViewer1 as all charts are update together in the
// winChartViewer1 ViewPortChanged event