Is there a way to disable the ability to add values to a xamdatachart via the zoombar. For example, I am using a double click event to add a point to the xamdatachart; however, if the user double clicks on the zoombar, it adds a point to the chart. Is it possible to disable this on the zoombar?
Hi Keicha,
Are you using the MouseDoubleClick event? If so, the e.OriginalSource will tell you whether the click was on the XamZoombar or the XamDataChart. Here is an example piece of code you can use to determine which.
DependencyObject originalSource = e.OriginalSource as DependencyObject; if (originalSource != null) { XamZoombar zoombar = (XamZoombar)Infragistics.Windows.Utilities.GetAncestorFromType(originalSource, typeof(XamZoombar), true); if (zoombar != null) { // zoombar was double clicked on. } }
Yes, it was the MouseDoubleClick event. This worked! Thank you for your help.
You are very welcome. Glad this was able to answer your question.