How do I pass recordsets from one page to another?

Results 1 to 6 of 6

Thread: How do I pass recordsets from one page to another?

  1. #1
    Charlie Pyne Guest

    Default How do I pass recordsets from one page to another?

    I&#039m working on a set of ASP pages that will first list a table of work orders that the user can view. When they click an individual work order, more detailed info will be returned. The detailed info will need to have a "labor" page and a "work description" page. The user will need to be able to switch back and forth between these two pages. There is a lot of data that needs to be retreived, so I&#039d like to not have to hit the database each time they switch beteen the "labor" page and "work description" page.. <BR><BR>How can I keep the recordsets in memory so that I can redisplay them as the user switches between views?<BR>

  2. #2
    Dumbledore Guest

    Default RE: How do I pass recordsets from one page to anot

    This is called maintaining state...There are 3 ways<BR><BR>1)Session("variables")<BR>2)Passing the variables through the querystring<BR>3)Passing the variable via a form using &#060;input type="hidden"&#062;

  3. #3
    Charlie Pyne Guest

    Default RE: How do I pass recordsets from one page to anot

    Ahhh... ok, I&#039ve been doing these already, it just didn&#039t click.<BR><BR><BR>One page displays 3 recordsets, 1 row, aprox 10 fields each..<BR>The other displays 6 recordsets, 1 row, aprox 15 fields each..<BR><BR>Any suggestion as to which method would be most suitable?

  4. #4
    Join Date
    Dec 1969
    Posts
    142

    Default RE: How do I pass recordsets from one page to anot

    A couple of possible solutions come to mind.<BR>- &#060;input type="hidden" name="SavedRS" value="&#060;%=yourRS%&#062;"&#062; might do it..<BR>Or<BR>- &#060;% <BR> Session.Contents("yourRS")=yourRS<BR> %&#062; and access the RS that way..<BR><BR>Let me know what works..


  5. #5
    MG Guest

    Default RE: How do I pass recordsets from one page to anot

    I don&#039t think passing this data from page to page is a good idea. Why not query the data on each page?

  6. #6
    Charlie Pyne Guest

    Default RE: How do I pass recordsets from one page to anot

    I&#039m trying the session method, but no luck so far.<BR><BR>session.contents("session_work_order_r s") = work_order_rs<BR>session.contents("session_labor_r s") = labor_rs<BR><BR>This is all its giving me...<BR><BR>Session object error &#039ASP 0185 : 8002000e&#039 <BR>Missing Default Property <BR>/get_DWO.asp, line 44 <BR>A default property was not found for the object<BR><BR><BR><BR>Any ideas?<BR><BR><BR><BR><BR>

Posting Permissions

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