DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

Creating a report with multiple Y-axes on one graph

I currently have a script that will create a report with either 1, 2, or 3 graphs and has the ability to have four graphs per plot.  I would like to add functionality to this script by making the Y-axis on the graphs have multiple Y-axes.  How can I programmatically create a graph with multiple Y-axes?
0 Kudos
Message 1 of 2
(3,372 Views)

To create an new axis system use the command GraphObjNew, eg:

Call GraphObjNew("2D-Axis","2DAxis1")
Call GraphObjOpen("2DAxis1")        
  D2AxisBackColor = "blue"  
Call GraphObjClose("2DAxis1") 
Call PicUpdate

If you have DIAdem Version 10 you can also create a new y-axis using GraphObjYAxisNew. This command is not available in versions 9.1:

Call GraphObjOpen("2DAxis1")
AxisNo = GraphObjYAxisNew("left")
If AxisNo>0 Then
  Call GraphObjOpen(D2AxisYObj(AxisNo))
  D2AXISYTXT ="My new axis"
  D2AXISYTXTFONT ="Arial"
  D2AXISYTXTCOLOR ="red"
  Call GraphObjClose(D2AxisYObj(AxisNo))
End If
Call GraphObjClose("2DAxis1")

Winfried

Message Edited by winner on 03-23-2006 03:48 PM

0 Kudos
Message 2 of 2
(3,371 Views)