Do Until calling another ASP page

Results 1 to 2 of 2

Thread: Do Until calling another ASP page

  1. #1
    Join Date
    Dec 1969

    Default Do Until calling another ASP page

    I am wanting to have a do while that sends data to another ASP page but am having problems doing this.<BR><BR><BR>... connections..<BR><BR>strSQL = "SELECT * FROM tblCompTest"<BR><BR>objRec.Open strSQL, strConnDataTest<BR><BR>if not objRec.EOF then<BR><BR> Do Until objRec.EOF<BR><BR>...<BR>send this item<BR>...<BR><BR>objRec("DeviceID_ID")<BR><BR>.. .<BR>to this page<BR>...<BR><BR>AdminTest_proc.asp<BR><BR>...<B R>so that AdminTest_proc.asp will see objRec("DeviceID_ID") as a request.querystring (ie, company1, company2, etc)<BR><BR>so that AdminTest_proc.asp processes the page, then comes back to this page for the next objRec("DeviceID_ID") <BR><BR><BR>...<BR><BR>objRec.MoveNext<BR>Loop<BR> <BR>end if<BR><BR><BR>Thanks.

  2. #2
    Join Date
    Dec 1969

    Default RE: Do Until calling another ASP page

    Why are you passing to another page to do the work? Why not just do the processing inside your loop?<BR><BR>If you call another page during the server side processing, the current page&#039;s processing is stopped there and then, so you&#039;d have to flag how far through that record set you had got to (say in a session variable) for when you came back to this page (not a good way of doing things). You&#039;d be much better off combining the two pages into one and looping though all the processing at once.<BR><BR>Alternatively, you could concattenate a comma delimited string out of that field of the record set and pass them all at once - but beware, some older browsers won&#039;t accept more than 255 characters in a querystring - also, you&#039;d just be looping through the same data twice, once to retrieve it and then once to process it - not very efficient.<BR><BR>HTH,<BR>Pete.

Posting Permissions

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