Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to do this?
Message
General information
Forum:
Internet
Category:
Active Server Page
Title:
Miscellaneous
Thread ID:
00564820
Message ID:
00565545
Views:
16
Thanks a lot Tom,

I'll try it out...

BR


>>Hi Fausto,
>>Thank you very much for your help.
>>
>>Is this mean that the Recordset will be closed and reopened every time user clicks Next or Previas ... Correct ?
>>
>>
>>
>>>Hello Ahmad!
>>>
>>>You can suppport all the tasks on a single ASP page using a parameter. First define the valid values your parameter will recognize, for example: if the page is requested with no parameter value then display the first record, use "P" for "Previous page" and "N" for "Next page". Then include the parameter value on your navigation tags. Assuming your page name is "gbook.asp" you could write:
>>>
>>>
href="gbook.asp?action=P"
>>>for the previous record anchor tag reference and
>>>
href="gbook.asp?action=N"
>>>for the next record anchor tag reference.
>>>
>>>Then you could code your page by analyzing the value of the parameter in your ASP code:
>>>
>>>
>>>value=Response.QueryString("action")
>>>if action="P" then
>>>   Retrieve previous record information here
>>>else
>>>   if action="N" then
>>>      Retrieve next record information here
>>>   else
>>>      Get and show first record info
>>>   end if
>>>end if
>>>
>>>
>>>Sorry for jumping in, but wanted to contribute with my two cents. Hope this helps!
>
>Ahmad;
>
>Yes, it will require a round trip to the server each time, unless you are using ADO RDS (Remote Data Services). RDS has pros and cons. If you have a lot of data it could be a bottleneck, but the term "a lot of data" is very subjective.
>
>I like Fausto's approach. Just test for End of File or Begining of File after doing a oRS.Recordset.MoveNext or oRS.Recordset.MovePrevious.
>
>If you want to look at a "Page" of data, that is a predetermined number of records on one web form in a table, let me know and I will send you the code. You can also have Next/Previous buttons for displaying pages of data.
>
>Tom
<><><><><><><><><><><><><><><><><><><><>
<><> REMEMBER,,,,KNOWLEDGE IS POWER <><>
<><><><><><><><><><><><><><><><><><><><>
Previous
Reply
Map
View

Click here to load this message in the networking platform