Does a response.redirect process the rest of the page?

Discussion in 'ASP General' started by Seth, Jun 26, 2004.

  1. Seth

    Seth Guest

    Pretty straight forward. Reason I'm asking is because I'm not sure if I
    should explicitly close my recordset and database connections before each
    redirect or get away with having a one time close at the bottom of my page.
    Thanks for the help.
    Seth, Jun 26, 2004
    #1
    1. Advertising

  2. Seth wrote:
    > Pretty straight forward. Reason I'm asking is because I'm not sure if
    > I should explicitly close my recordset and database connections
    > before each redirect or get away with having a one time close at the
    > bottom of my page. Thanks for the help.


    Redirect does what it says. Nothing else is processed. My practice is to
    process database objects first, closing and destroying them when fineshed.
    THEN make decisions as to whether to redirect or not.

    Bob Barrows
    --
    Microsoft MVP - ASP/ASP.NET
    Please reply to the newsgroup. This email account is my spam trap so I
    don't check it very often. If you must reply off-line, then remove the
    "NO SPAM"
    Bob Barrows [MVP], Jun 26, 2004
    #2
    1. Advertising

  3. Bob Barrows [MVP] wrote:
    > Seth wrote:
    >> Pretty straight forward. Reason I'm asking is because I'm not sure if
    >> I should explicitly close my recordset and database connections
    >> before each redirect or get away with having a one time close at the
    >> bottom of my page. Thanks for the help.

    >
    > Redirect does what it says. Nothing else is processed. My practice is
    > to process database objects first, closing and destroying them when
    > fineshed. THEN make decisions as to whether to redirect or not.
    >

    Just to clarify, by "process", I mean:
    Assign the data contained in the database objects to variables (including
    using GetRows to assign the data to an array, or GetString to create a
    string containing the data, if I need to process multiple records). After
    this operation, there is no longer any need to keep the database objects
    open, so at this point, I close and destroy them.

    NOW I process the variables containing the data, writing them to response,
    or making decisions as to whether or not to redirect, etc.

    Bob Barrows

    --
    Microsoft MVP - ASP/ASP.NET
    Please reply to the newsgroup. This email account is my spam trap so I
    don't check it very often. If you must reply off-line, then remove the
    "NO SPAM"
    Bob Barrows [MVP], Jun 26, 2004
    #3
  4. Seth

    Seth Guest

    Thanks for the help. Seems like I've got quite a bit of change, I've assumed
    that the rest of the page is processed.

    "Bob Barrows [MVP]" <> wrote in message
    news:...
    > Bob Barrows [MVP] wrote:
    > > Seth wrote:
    > >> Pretty straight forward. Reason I'm asking is because I'm not sure if
    > >> I should explicitly close my recordset and database connections
    > >> before each redirect or get away with having a one time close at the
    > >> bottom of my page. Thanks for the help.

    > >
    > > Redirect does what it says. Nothing else is processed. My practice is
    > > to process database objects first, closing and destroying them when
    > > fineshed. THEN make decisions as to whether to redirect or not.
    > >

    > Just to clarify, by "process", I mean:
    > Assign the data contained in the database objects to variables (including
    > using GetRows to assign the data to an array, or GetString to create a
    > string containing the data, if I need to process multiple records). After
    > this operation, there is no longer any need to keep the database objects
    > open, so at this point, I close and destroy them.
    >
    > NOW I process the variables containing the data, writing them to response,
    > or making decisions as to whether or not to redirect, etc.
    >
    > Bob Barrows
    >
    > --
    > Microsoft MVP - ASP/ASP.NET
    > Please reply to the newsgroup. This email account is my spam trap so I
    > don't check it very often. If you must reply off-line, then remove the
    > "NO SPAM"
    >
    >
    Seth, Jun 26, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?VHJveQ==?=

    Response.redirect does not redirect from .aspx page

    =?Utf-8?B?VHJveQ==?=, Oct 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    5,215
    Srowe1975
    Oct 15, 2008
  2. André
    Replies:
    3
    Views:
    1,887
    André
    Dec 1, 2006
  3. Sal
    Replies:
    1
    Views:
    375
  4. Ron Howard
    Replies:
    2
    Views:
    504
    Ron Howard
    Aug 11, 2004
  5. Keiron Waites
    Replies:
    2
    Views:
    91
    VBDude
    Aug 8, 2003
Loading...

Share This Page