Sub Globals
Dim myTable As Table
End Sub
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("TableFr")
Dim head(5) As String
myTable.Initialize(Me, "MyTable", 6, Gravity.CENTER_HORIZONTAL, False)
myTable.HeaderColor = Colors.Green
myTable.HeaderTextColor = Colors.Black
myTable.RowColor1 = Colors.RGB(255,222,173)
myTable.RowColor2=Colors.RGB(255,222,173)
myTable.SelectedCellColor=Colors.Yellow
myTable.SelectedRowColor=Colors.Yellow
myTable.StatusLineAutoFill=False
myTable.StatusLine=""
myTable.TableColor=Colors.Black
myTable.TextColor=Colors.Black
myTable.CellAlignment = Bit.Or(Gravity.RIGHT, Gravity.CENTER_VERTICAL)
myTable.AddToActivity(Activity, 0, 50, Activity.Width, Activity.Height-50)
If Main.mcode=24 Then
head(0)="Uur"
head(1)="Gas m³"
head(2)="Elec KWh"
head(3)="° C."
myTable.SetColumnsWidths(Array As Int(100,185,185,75))
else if Main.mcode=25 Then
head(0)="Dag"
head(1)="Gas m³"
head(2)="Elec KWh"
head(3)="° C."
myTable.SetColumnsWidths(Array As Int(100,185,185,75))
else if Main.mcode= 26 Then
head(0)="Jaar"
head(1)="Week"
head(2)="Gas m³"
head(3)="Elec KWh"
head(4)="° C."
myTable.SetColumnsWidths(Array As Int(100,100,135,135,75))
else if Main.mcode=27 Then
head(0)="Dag"
head(1)="Gas m³"
head(2)="Elec KWh"
head(3)="° C."
myTable.SetColumnsWidths(Array As Int(100,185,185,75))
else if Main.mcode=28 Then
head(0)="Jaar"
head(1)="Maand"
head(2)="Gas m³"
head(3)="Elec KWh"
head(4)="° C."
myTable.SetColumnsWidths(Array As Int(100,100,135,135,75))
End If
myTable.SetHeader(head)
myTable.ClearAll
myTable.Visible=True
End Sub