From Xojo Documentation

You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!

Property (As ListBox.Alignments )
aDesktopListBox.ColumnAlignmentAt(ColumnNumber as Integer) = newListBox.AlignmentsValue
ListBox.AlignmentsValue = aDesktopListBox.ColumnAlignmentAt(ColumnNumber as Integer)

New in 2021r3

Supported for all project types and targets.

Aligns the specified column. The first column is numbered zero.


You specify the alignment via the DesktopListBox.Alignments enumeration.


Set right alignment:

ListBox1.ColumnAlignmentAt(1) = DesktopListBox.Alignments.Right

Decimal aligns the decimal separator to the right edge of the column. You need to use ColumnAlignmentOffsetAt to move the alignment point in the column.