DIAdem Help

Method: Add for Columns

  • Updated2024-09-12
  • 1 minute(s) read

Method: Add for Columns

Adds an object to the Columns collection and returns a Column object in the script interface of DIAdem VIEW.

Set oColumn = Object.Add(NameOrNo)
ObjectColumns
Object with this method
NameOrNoVariant
Specifies the number or the name of the channel to be displayed.
oColumnColumn
Returned object

The following example illustrates how you can add worksheets, curves, legend entries, table columns, or table titles:

VBScriptPython

 

Call View.Sheets.RemoveAll()
Dim oMySheet: Set oMySheet = View.Sheets.Add("NewSheet")
Dim oOldArea: Set oOldArea = oMySheet.ActiveArea
oOldArea.DisplayObjType = "CurveChart2D"
Call oOldArea.DisplayObj.Curves2D.Add("[1]/[1]","[1]/[3]")
Call oOldArea.DisplayObj.LegendItems.Add("Name")
Dim oNewArea: Set oNewArea = oMySheet.ActiveArea.SplitTop("NewArea",0.5) 
oNewArea.DisplayObjType = "ChannelTable"
Call oNewArea.DisplayObj.Columns.Add(3)
Call oNewArea.DisplayObj.HeaderItems.Add("Name")