07-12-2005 07:23 AM
07-12-2005 08:23 AM
07-13-2005 12:00 AM
07-13-2005 12:29 AM
Is it possible for you to load a report file which already has these two axis and then programmatically change everything you have to?
You can get all VBScript commands possible for the diagram by double-clicking the diagram, then pressing CTRL+A (or STRG+A) and copying with CTRL+V into the VBScript.
This is also possible for sub axis and should give you this:
Call GRAPHObjOpen("2DAxis1")
Call GRAPHObjOpen("2DXAxis1_1")
D2AXISYOFFSET =0
D2AXISYOFFORIGIN ="AxisOrigin"
Call GRAPHObjClose("2DXAxis1_1")
Call GRAPHObjOpen("2DYAxis1_1")
D2AXISXOFFSET =0
D2AXISXOFFORIGIN ="AxisOrigin"
Call GRAPHObjClose("2DYAxis1_1")
Call GRAPHObjOpen("2DYAxis1_2")
D2AXISXOFFSET =-8
D2AXISXOFFORIGIN ="AxisOrigin"
Call GRAPHObjClose("2DYAxis1_2")
Call GRAPHObjClose("2DAxis1")
Hope this helps
07-14-2005 02:06 AM
hi TheMad,
Suppose if im loading a Graph with just the axis alon, and is it possible to assign the channels to be plotted dynamically ? Because, the channels to be plotted on the axis varies ....Sometimes in a Channel group, atleast one channel has to be assigned to the first y-axis and may be 2 or 3 channels might correspond to the 2 nd y-axis.....in such case, is it possible to load the axis template and then assign the channels using VBscript ?
Then , the code which you had suggested me doesnot work when it is executed as a VBS file....I dont both the axis but just one axis everytime I run that file...
Expecting your reply...........
With Regards
Philip
07-14-2005 02:31 AM
07-14-2005 07:48 AM
Thanks Walter, It working fine.....
I do have another issue....when i load the TDR files and plot the values, graph gets plotted . But immdiately after which if I load somemore datas and try plotting them on the sheet (single x-y axis whose axis definition and other definitions are done programmatically) , the curves does not get plotted on the sheet, but i do see all the curves getting listed in the "properties dialogue box"
This is the same case even if it is the other way round. Whenever I run these two programs alternatively i face this problem....
What could be the reason for this?
Expecting your reply
Regards
Philip
07-15-2005 03:51 PM
Hi Phillip,
I am not sure what is causing the behavior you’ve described, but I have attached a new version of the Test VBScript that Walter posted. This script does what it did before and then it loads more data and plots data to another axis. I edited the Test.TDR to include a second 2D-axis system.
Regards,
Eric M
08-31-2009 05:31 PM
Hey guys,
I am trying to create 2 Y-Axis automatically as the author of this post described.
Has the capability been integrated into DIAdem 11.0? And if so, what should I do?
Thank you
Egor
09-01-2009 10:26 AM
Hi Egor,
Yes, this is available in DIAdem 11.0 and described in the Help system-- here's the syntax to use:
Call GraphObjOpen("2DAxis1")
AxisIndex = GraphObjYAxisNew("Right")
MsgBox "New Right Axis Index = " & AxisIndexAxisIndex = GraphObjYAxisNew("Left")
MsgBox "New Left Axis Index = " & AxisIndex
Call GraphObjClose("2DAxis1")
Call PicUpdate
Brad Turpin
DIAdem Product Support Engineer
National Instruments