From Xojo Documentation

Revision as of 23:35, 4 February 2022 by Gperlman (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
You are currently browsing the old Xojo documentation site. Please visit the new Xojo documentation site!

Class (inherits from MobileUIControl)

New in 2020r2

An iOSTable is used for displaying a list of data.

AccessoryPressed Closing RowActionSelected
ApplyActionsForRow Opening SearchChanged
ApplyRowEditingStyle Refreshed SelectionChanged
AddConstraint CreateCustomCell RemoveRowAt
AddControl EndRefresh RemoveSectionAt
AddRow Refresh RowCellData
AddRowAt ReloadDataInSection RowCount
AddSection ReloadDataSource ScrollToRow
AddSectionAt ReloadRow SearchControllerHandle
ClearFocus RemoveAllRows SectionTitleAt
ControlAt RemoveConstraint SelectRow
CreateCell RemoveControl SetFocus
AccessibilityHint EstimatedRowHeight SectionCount fa-lock-32.png
AccessibilityLabel Format fa-lock-32.png SelectedRow fa-lock-32.png
AllowRefresh Height fa-lock-32.png Top fa-lock-32.png
AllowSearch Left fa-lock-32.png Visible
DataSource Name fa-lock-32.png Width fa-lock-32.png
EditingEnabled Parent fa-lock-32.png

Constructor(format As Formats)

Formats RowEditingStyles ScrollPositions


An iOSMobileTable has only a single column of cells so by default it can only show one column of data. Use MobileTableCustomCell to create your own cells with your own cell layout. This allows you to have a cell with its own controls or even multiple columns.

A table can have data added to it in one of two ways: manually or from a data source. Some methods only work with data that was added manually, some methods only work with data added using a data source. If you are adding many rows (100+), you should instead use an iOSMobileTableDataSource for better performance and reduced memory usage.

A table must have at least one section (0-based). If there is only one section, then the section title does not appear in the table.

Sample Code

Add five rows to a table:

// Simple usage
For i As Integer = 0 To 4
Table1.AddRow(0, "Row " + i.ToString)

See Also

MobileTableCustomCell control; MobileTableCellData, iOSMobileTableRowAction classes; iOSMobileTableDataSource, iOSMobileTableDataSourceEditing, iOSMobileTableDataSourceReordering interfaces; UserGuide:iOS_Table topic