I need a simple table (2 columns, 4 to 10 rows)
I wish to populate this table with data values that are stored in an arrays
I am using Diadem 2019SP1
I have seen previous posting for older versions of Diadem, but they did not use the Reports object model.
Using a 2dTable of column type e2DTableColumnExpression I can use an expression to populate it with a variable.
But how do I get the value of each array element into each row? Currently I am hardcoding a specific index in the Expression property
GlobalDim("sCalcValues")
GlobalDim("sCalcDesc")
sCalcDesc = Array ("Res 01", "Res 0", "Res 03", "Res 04", "Res 05")
sCalcValues = Array("1.23", "2.23", "3.333", "3.45", "3.165")
Dim oMy2DTable, oMyPosition, oMyColumn
Call Report.NewLayout()
Set oMy2DTable = Report.ActiveSheet.Objects.Add(eReportObject2DTable,"My2DTable")
Set oMyPosition = oMy2DTable.Position.ByBorder
oMyPosition.Top = 30
oMyPosition.Bottom = 20
oMyPosition.Left = 20
oMyPosition.Right = 30
Set oMyColumn = oMy2DTable.Columns.Add(e2DTableColumnExpression)
oMyColumn.Expression = "@@sCalcValues(2)@@"
oMyColumn.ExpressionMaxIndex = 3
oMyColumn.Settings.Font.Color.SetpredefinedColor(ePredefinedColorBlue)
oMy2DTable.Settings.IndexSettings.IndexMode = e2DTableIndexModeAutomaticMinimum
Call Report.Refresh()
oMyColumn.
oMyColumn.Settings.Font.Color.SetpredefinedColor(ePredefinedColorBlue)
oMy2DTable.Settings.IndexSettings.IndexMode = e2DTableIndexModeAutomaticMinimum
Call Report.Refresh()