AHilberink Active Member Licensed User Longtime User Dec 12, 2022 #1 Hi, I have a B4XTable with two pages. 2 Columns - 3 Row per page I need the number of the cell with is Clicked B4X: First column Second column 1 2 3 4 5 6 Next page 7 8 9 10 11 12 etc I cannot findout how to do this. Is there a way to get this number? Kind regards, André
Hi, I have a B4XTable with two pages. 2 Columns - 3 Row per page I need the number of the cell with is Clicked B4X: First column Second column 1 2 3 4 5 6 Next page 7 8 9 10 11 12 etc I cannot findout how to do this. Is there a way to get this number? Kind regards, André
AHilberink Active Member Licensed User Longtime User Dec 12, 2022 #2 I finally find my answer: The RowID of the CellClicked Event is independed of the page, so on page 2 the first RowID is 4 etc. So this works fine: B4X: Private NumberOfColumns As Int = 2 Sub B4XTable1_CellClicked (ColumnId As String, RowId As Long) Log(((RowId-1)*NumberOfColumns)+ColumnId+1) End Sub Kind regards, André Upvote 0
I finally find my answer: The RowID of the CellClicked Event is independed of the page, so on page 2 the first RowID is 4 etc. So this works fine: B4X: Private NumberOfColumns As Int = 2 Sub B4XTable1_CellClicked (ColumnId As String, RowId As Long) Log(((RowId-1)*NumberOfColumns)+ColumnId+1) End Sub Kind regards, André