Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » Getting Primary Y-Axis to Match Secondary Y-Axis
Getting Primary Y-Axis to Match Secondary Y-Axis [message #1086808] Wed, 14 August 2013 19:02 Go to next message
Adam Brousseau is currently offline Adam BrousseauFriend
Messages: 1
Registered: August 2013
Junior Member
Hello all,

I am working with BIRT 3.7.2 and have a query that returns the following fields.

Average Max Quantity, Average Max Weight, Max Quantity, Max Weight, and Date

The user is able to select from either quantity or weight and I have a chart with two y-axis to display the average as a bar and the maximum as a line. The reason for this is to allow potential outlyers be identified by the user. I was looking for some help to script setting both y-axis values to the same values. For example if the secondary y-axis goes from 0 to 100 then I want that to reflect on the primary y-axis as well. This way I am not displaying two y-axis with labels. As I will not know what the values are ahead of time scripting is my only option. Below is some scripting that I have found that doesn't work, though I believe this is a similar attempt to what I am working towards. Any help would be most appreciative.


Adam Brousseau

importPackage( );

var cht = reportContext.getDesignHandle().findElement("Chart1");
var chart = cht.getReportItem().getProperty("chart.instance");

xAxis = chart.getBaseAxes()[0];
yAxis1 = chart.getOrthogonalAxes( xAxis, true)[0];
yAxis2 = chart.getOrthogonalAxes( xAxis, true)[1];
yscale1 = yAxis1.getScale();
yscale2 = yAxis2.getScale();
yscale2_min = yscale2.getMin();
yscale2_max = yscale2.getMax();
yscale2 = yscale1;
Re: Getting Primary Y-Axis to Match Secondary Y-Axis [message #1087515 is a reply to message #1086808] Thu, 15 August 2013 19:21 Go to previous message
Michael Williams is currently offline Michael WilliamsFriend
Messages: 1925
Registered: July 2009
Senior Member

Linking this with the same post on BIRT Exchange:

Getting Primary Y-Axis to Match Secondary Y-Axis


Developer Evangelist, Silanis
Previous Topic:Multi-Series Gantt Chart Task Labels Not Showing
Next Topic:How to pass dataSetRow[] values in a Crosstab Within a Table
Goto Forum:

Current Time: Wed Feb 26 07:43:27 GMT 2020

Powered by FUDForum. Page generated in 0.01890 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top