Results 1 to 8 of 8
  1. #1
    Join Date
    Mar 2004
    Location
    Montreal
    Posts
    3

    Unanswered: Paging Records in ASP

    I've found a few sites about paging recordsets in ASP as well as the thread on this board and I have used so many examples on how to page through records. I keep getting the same problem. I have a search and when the search returns the results on the 2nd page, you see the first 5 results of the query. Good. But when I click on the first/previous/next/last buttons, it navigates the 5 records through ALL the records and not just the results from the query. Any tips or suggestions where my error could be, would be very helpful. Thanks.

  2. #2
    Join Date
    Dec 2003
    Posts
    454
    No very clear to your question. What does it mean?

    "it navigates the 5 records through ALL the records and not just the results from the query."

  3. #3
    Join Date
    Jun 2003
    Location
    USA
    Posts
    1,032
    Maybe the criteria used in the first (good) SQL statement needs to be saved in session variables for future use.
    J. Paul Schmidt, Freelance Web and Database Developer
    www.Bullschmidt.com
    Access Database Sample, Web Database Sample, ASP Design Tips

  4. #4
    Join Date
    Mar 2004
    Location
    Montreal
    Posts
    3

    Red face

    Sorry, I'll try to explain it better:

    I have a search and results come up. Let's say there are 830 records in my database and my search brings up 40. So my results page displays the first 5 of the 40. When I click "next", it displays the second set of 5 out of my 830 records.

  5. #5
    Join Date
    Mar 2004
    Location
    Nairobi
    Posts
    6
    Check if you are passing the search criteria when you click "Next".

    For example if your search begins at a form with a textbox called SearchBox and you are passing the criteria through a querystring your URL should have something like ?SearchBox=MySearchTerm at the end of it, make sure that when you click on "Next" you are passing the querystring in the URL for "Next".

  6. #6
    Join Date
    Mar 2004
    Location
    Montreal
    Posts
    3
    Okay I got it working! I used a hidden field to pass my sql query and made sure all my links submittied. Thanks!

  7. #7
    Join Date
    Jun 2004
    Posts
    2

    Question String Validation Using Vb Script

    Is there any function in vb script that helps us to checks that
    the input entered in textbox is Alpha
    Plz

  8. #8
    Join Date
    Dec 2003
    Posts
    454
    There is no specific function in VB Script to check if the input is alphabetic string, but you can create one or you can use JavaScript to check the input on the client browser.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •