Android Question TableView problem

Sreenadh OG

Member
Licensed User
Hi all,
I have a table contain six column, so i want scroll this table horizontally, ..
My code is shown below...
B4X:
Sub Activity_Create(FirstTime As Boolean)
    SV.Initialize(0) 'ScrollView
    Table = SV.Panel
    Table.Color = TableColor
    Activity.AddView(SV, 5%x, 10%y, 100%x, 80%y)
    ColumnWidth = SV.Width / NumberOfColumns
    SelectedRow = -1
    'add header
    SetHeader(Array As String("Col1", "Col2", "Col3", "Col4","New","Name"))
    'add rows
    For i = 1 To 100
        AddRow(Array As String(i, "Some text", i * 2, "abc",i+1,i+2))
    Next
    'set the value of a specific cell
    SetCell(0, 3, "New value")
    'get the value
    Log("Cell (1, 2) value = " & GetCell(1, 2))
End Sub
How can i scroll this table horizontally?
 

klaus

Expert
Licensed User
In the upper right corner of the forum page you have the search box.
Enter ScrollView2D and the second item is what you are looking for.

You didn't answer the question What TableView are you talking about ?
 

Sreenadh OG

Member
Licensed User
I want display the content form database to table, i don't know more about tableview, And i want to get the details of selected row.
so which one is suitable for me .
 
Last edited:
Top