LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I retrieve the right y-axis precision when the precision is set to "AUTO"?

I have tried setting the right y-axis as the active y-axis and then calling
GetCtrlAttribute (panel, PANEL_GRAPH, ATTR_ACTUAL_YPRECISION, &precision) but this still always returns the precision of the left y-axis.
0 Kudos
Message 1 of 2
(2,831 Views)
You are doing it right, but remember SetCtrlAttribute does not update the attributes until you process the events. Put in a call to ProcessSystemEvents() after setting the Active Y Axis and it will work. As in:

SetCtrlAttribute (panelHandle, PANEL_GRAPH, ATTR_ACTIVE_YAXIS,
VAL_RIGHT_YAXIS);
ProcessSystemEvents();
GetCtrlAttribute (panelHandle, PANEL_GRAPH, ATTR_ACTUAL_YPRECISION,
&value);

Best Regards,

Chris Matthews
Measurement Studio Support Manager
0 Kudos
Message 2 of 2
(2,831 Views)