Search Pagination Error

jothis

Active Member
Licensed User
Pagination

Hi Friends,

I Writed A Pagination Script For easy search But The Next And Previous Buttons Are Not Working

I Attached My Sample Code here
Please Help Me

Jothis
:sign0085:
 

Attachments

  • pagination.zip
    4.1 KB · Views: 211
Last edited:

mjcoon

Well-Known Member
Licensed User
How isn't it working? Do you get an error message?

I think that Jothis is complaining that the program does not do what he expects, though he has not told us what that is, nor what it actually does.

Looking at the code, I discover that he has found how to scroll through an SQL database, loading just a portion (say, a screenfull) into a table for viewing. In my post http://www.b4x.com/forum/questions-help-needed/7697-how-close-sql-database-regain-its-memory-2.html#post44050 I said that I thought that was, sadly, a non-starter, though it would solve Sarah's problem with a table holding all of the database content being too big for device memory. (Hint: the solution is use of LIMIT and OFFSET clauses.)

The probable reason for Jothis's version misbehaving may be that both his forward and back buttons call the same "Pagination" Sub without using any parameter to tell it which way to paginate (or, I would say, "scroll").

If I were Jothis, I would also not use a variable as both a string, as in expression
B4X:
newp=""
and also as an integer. Doing this has given me problems with my own code!

Mike.
 
Top