Android Question [Solved] How do I go to the last page of a B4XTable view by code?

Sergio Castellari

Active Member
Licensed User
Hello there,
I need that when displaying a B4Xtable, initially the last page of it is displayed using code.
Greetings
 
Solution
need that when displaying a B4Xtable, initially the last page of it is displayed using code.
See Erel's post #4 for the solution to your thread here:

Mahares

Expert
Licensed User
Longtime User
need that when displaying a B4Xtable, initially the last page of it is displayed using code.
See Erel's post #4 for the solution to your thread here:
 
Upvote 2
Solution

Sergio Castellari

Active Member
Licensed User
Thank you very much @Mahares !!!
It works like this:

B4X:
B4XTable1.SetData(aRegistros)  'Aquí cargo los datos en la tabla
Sleep(100)
'Para posesionarse en la ultima Pagina de la consulta
If B4XTable1.mCurrentCount > 0 Then
    Dim NumberOfPages As Int = Ceil(B4XTable1.mCurrentCount / B4XTable1.VisibleRowIds.Size)
    Log("Nro.De Paginas: "&NumberOfPages)
    B4XTable1.CurrentPage = NumberOfPages - 0
End If
        B4XTable1.Refresh

Big hug!
 
Upvote 0
Top