iOS Tutorial TableView with custom items

iTableView v1.20 adds support for custom items.

Each TableCell includes a CustomView property. You can set a Panel with views to this property and the panel will be added to the cell.


It is quite similar to CustomListView class. However TableView is more powerful.
Do note that when you create custom views your TableView will be limited to about 1000 items as each cell holds its own custom views (the standard cells are reused and therefore support any number of cells).

The attached example adds cells based on a designer layout file:
For i = 1 To 50
     Dim tc As TableCell = tv.AddSingleLine("")
     tc.ShowSelection = False
     tc.CustomView = CreateItem

Private Sub CreateItem As Panel
   Dim p As Panel
   p.Width = 100%x
   p.Height = tv.RowHeight
   Return p
End Sub

You will usually want to explicitly set the RowHeight property before creating the items. The default value of this property is not useful for custom items.

The table cells are resized in the Page_Resize event. The TextField is anchored to both sides so it will fill the entire space when you rotate the device.


    4.2 KB · Views: 1,468

Daniel Uribe

Licensed User
Longtime User
Hi Erel,

A little question, how can i erase the white line separator for each row?
? An example on the screenshot. i´m using the first post example.

Thanks a lot.!!


  • img_prueba.jpg
    121.3 KB · Views: 556


Licensed User
Longtime User
Is there a way to change the backgroundcolour of the Cell? and the selected cell colour?