Private Sub Application_Start (Nav As NavigationController)
'SetDebugAutoFlushLogs(True) 'Uncomment if program crashes before all logs are printed.
NavControl = Nav
Page1.Initialize("Page1")
Page1.Title = "Page 1"
Page1.RootPanel.Color = Colors.White
NavControl.ShowPage(Page1)
Page1.RootPanel.LoadLayout("Layout1")
FlexGrid1.ColsName=Array As String("Num","Selc","Name","Img","Digit")
FlexGrid1.ColsWidth=Array As Int(75dip,50dip,100dip,60dip,150dip)
FlexGrid1.ColsType=Array As Int(FlexGrid1.TypeInt,FlexGrid1.TypeCheck,FlexGrid1.TypeString,FlexGrid1.TypeImage,FlexGrid1.TypeFloat)
FlexGrid1.ColsAlignment=Array As String("CENTER","CENTER","LEFT","LEFT","RIGHT")
Dim B As Boolean=False
For i=1 To 25
B=Not(B)
FlexGrid1.AddRow(Array As Object(i,B,"User " & i,Null,Rnd(50,10000)/100))
Next
FlexGrid1.SetCell(0,0,100)
FlexGrid1.SetCell(1,2,"User 200")
FlexGrid1.SetCell(0,3,LoadBitmap(File.DirAssets,"b4a.png"))
FlexGrid1.SetCell(2,3,LoadBitmap(File.DirAssets,"b4j.png"))
FlexGrid1.SetCell(4,3,LoadBitmap(File.DirAssets,"b4i.png"))
FlexGrid1.Invalidate
End Sub
Sub FlexGrid1_HeadClick(Index As Int) ' Click Header Column
FlexGrid1.Selectcol(Index) ' Select all cell of column
End Sub