tc_blr has asked for the wisdom of the Perl Monks concerning the following question:

Hi, i have a chart with two series' for the y axis. i am using Spreadsheet::WriteExcel to create these charts. Is it possible that I could display the data and name for the 2nd Y-axis as well? If yes, How? Please suggest... i tried the following but it is not working because the value of hash key name is being overwritten in the later part of the below given code. Code:-
# #some more code # $chartsheet=$workbook2->add_worksheet('Chart'); $chart=$workbook2->add_chart(type=>'line', embedded=>1); $chart->set_plotarea(weight=>'none'); $chart->add_series( categories=>xl_range_formula('series1',1,$row_max,1,1), values=>xl_range_formula('series1',1,$row_max,3,3), name=>'series1' ); $chart->set_y_axis(name=>'Y-axis1'); $chart->add_series( categories=>xl_range_formula('series2',1,$row_max,1,1), values=>xl_range_formula('series2',1,$row_max,5,5), name=>'series2' ); $chart->set_y_axis(name=>'Y-axis2'); $chart->set_x_axis(name=>'X-axis'); $chartsheet->insert_chart(0,0,$chart,0,0,1,1);
Is there any workaround to this?

Replies are listed 'Best First'.
Re: Display 2nd Y-axis in Spreadsheet::WriteExcel
by Anonymous Monk on Apr 02, 2013 at 13:33 UTC

    That isn't possible with Spreadsheet::WriteExcel.

    However, it is possible with Excel::Writer::XLSX: Example.

      Got it...Thanks for ur response...!