04-19-2013 09:27 AM
Hello,
I am currently working on LabWindowsCVI and I treat my data in excel files. I use ExcelReport and Excel2000 instruments to build my data tables and my graph. To trace, I use this function:
ExcelRpt_ChartWizard (chartsheetHandle, ExcelWorksheetHandle, "A1: C619" ExRConst_XYScatterSmoothNoMarkers 0, ExRConst_Columns, 1, 1, 1, "Consumption mobile plateform", "TIME (sec)", "Current / Voltage (in V & A in)" , NULL);
In this configuration, column A is X axis and B & C (Y axis) my respective data voltage & current.
My graph are traced correctly, but I find a problem, 2 curves are on the main axis and I want to trace one on the main axis and the other on the secondary axis. I can't to display a secondary axis.
Does this action is it possible with a LabwindowsCVI function and if so, can you tell me that function?
Thank you in advance,
Nicolas
Solved! Go to Solution.
04-23-2013 09:40 AM
Duplicate, continues here (in french)
04-24-2013 12:47 PM
Hi! nlepouliquen,
First of all, I believe you have two curves successfully plotted on the chart as you mentioned. Excel asigns these two curves as data series 1 and 2 internally. Assume you want to change series 2 to be plotted against the sencond Y-axis. You can use the following two functions, defined in excel2000.c, to do it.
// select series 2 data
Excel_ChartSeriesCollection (chartsheetHandle, NULL, CA_VariantInt(2), &seriesTwoHandle);
// create the second Y-axis and plot series 2 data against it
Excel_SetProperty (seriesTwoHandle, NULL, Excel_SeriesAxisGroup, CAVT_LONG, ExcelConst_xlSecondary);
04-25-2013 02:07 AM
Thank you very much dcl9000,
I wrote these functions after to trace my graph and secondary axis appears :). It was necessary to create a second chart handle to separate my both curve. Thanks to you, now, I know a new Excel function and I think I will need it in the future.
Regards,
Nicolas