### Set Columns with different alignment & colors

How to set the columns to different alignment and colors?
TableView (like ListView) allows you to add Nodes instead of strings.
This way you can fully customize it.
`Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
MainForm.Show
tv.Initialize("tv")
MainForm.RootPane.AddNode(tv, 0, 0, 250, 250)
tv.SetColumns(Array As String("col1", "col2"))
For i = 1 To 100
Dim lbl1, lbl2 As Label
lbl1.Initialize("")
lbl2.Initialize("")
lbl1.Text = i
lbl2.Text = i
lbl1.Font = fx.DefaultFont(Rnd(10, 20))
lbl2.Font = fx.DefaultFont(Rnd(10, 20))
lbl1.TextColor = fx.Colors.From32Bit(Rnd(0x80000000, -1))
lbl2.TextColor = fx.Colors.From32Bit(Rnd(0x80000000, -1))
tv.Items.Add(Array As Object(WrapLabel(lbl1, "CENTER") , _
WrapLabel(lbl2, "CENTER_RIGHT")))
Next
End Sub`
`Sub WrapLabel(lbl As Label, Alignment As String) As Pane
Dim pn1 As AnchorPane
pn1.Initialize("")
pn1.AddNode(lbl, 0, 0, -1, -1)
pn1.FillHorizontally(lbl, 0, 0)
Dim jo1 = lbl As JavaObject
jo1.RunMethod("setAlignment", Array As Object(Alignment))
Return pn1
End Sub`

Changed: , Category: TableView, File: T6C259M1900.htm, ID: 1900