Hi kelvin,
Thanks for using the Syncfusion products.
We have analysed the reported query. We would like to inform you that the requirement achieved by workaround in sample. Please find the sample under the following location. And we do not have any public API to custom the left and right mouse sector zooming.
Please let us know if you require further assistance on this.
Thanks,
Karthikeyan V.
m_chartArea.EnableMouseDragZooming = true;ChartAreaCommands.ZoomSector.Execute(rect, m_chartArea);m_chartArea.EnableMouseDragZooming = false;m_startZoomBarPoint = new Point();m_endZoomBarPoint = new Point();
Hi Kelvin,
Thank for the update.
We have analysed the reported requirement. We have checked your code that the code is also best way to achieve your requirement. But we are suggesting one more solution for this requirement in below code. Please find the code snippet under the following location.
Code Snippet [C#]:
bool isLeftZooming = false;
private void area_MouseDown(object sender, MouseButtonEventArgs e)
{
ChartArea area = sender as ChartArea;
if (e.ChangedButton == MouseButton.Left && !area.AllowSegmentDragDrop)
{
area.AllowSegmentDragDrop = true;
isLeftZooming = true;
}
…….
}
private void area_MouseMove(object sender, MouseEventArgs e)
{
ChartArea area = sender as ChartArea;
if (e.LeftButton == MouseButtonState.Pressed && isLeftZooming)
{
area.AllowSegmentDragDrop = false;
isLeftZooming = false;
}
………
}
private void area_MouseUp(object sender, MouseButtonEventArgs e)
{
ChartArea m_chartArea = sender as ChartArea;
if (e.ChangedButton == MouseButton.Left)
{
isLeftZooming = false;
}
…..
}
Please let us know if you require further assistance on this.
Thanks,
Karthikeyan V.