473,473 Members | 2,166 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

what does this really do?

hey all,

i was wondering what the true/false really does in the
response.redirect("default.aspx", false)?

thanks,
rodchar
Nov 19 '05 #1
3 1097
On Tue, 14 Jun 2005 23:15:16 -0500, rodchar
<ro*****@discussions.microsoft.com> wrote:
hey all,

i was wondering what the true/false really does in the
response.redirect("default.aspx", false)?

thanks,
rodchar


It tells the code whether it should keep running to completion after
redirecting the client (run the lines after the Response.Redirect
statement). You can tell the code to keep running the lines after
Response.Redirect, even after the client has received the 302 response for
the redirect. I've never done it for this reason myself, but this
argument comes in very handy if you are doing a Redirect within a
try...catch. By default it would throw an exception to abort the current
thread (which is usually ignored by the framework), but if inside a
try...catch of yours, the exception would get caught by your try..catch
and cause you to think an error happened, when really it's just part of
normal processing (it's how a redirect 'normally' works)...

--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET
Nov 19 '05 #2
thank you very much. i appreciate it.
rodchar

"Craig Deelsnyder" wrote:
On Tue, 14 Jun 2005 23:15:16 -0500, rodchar
<ro*****@discussions.microsoft.com> wrote:
hey all,

i was wondering what the true/false really does in the
response.redirect("default.aspx", false)?

thanks,
rodchar


It tells the code whether it should keep running to completion after
redirecting the client (run the lines after the Response.Redirect
statement). You can tell the code to keep running the lines after
Response.Redirect, even after the client has received the 302 response for
the redirect. I've never done it for this reason myself, but this
argument comes in very handy if you are doing a Redirect within a
try...catch. By default it would throw an exception to abort the current
thread (which is usually ignored by the framework), but if inside a
try...catch of yours, the exception would get caught by your try..catch
and cause you to think an error happened, when really it's just part of
normal processing (it's how a redirect 'normally' works)...

--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET

Nov 19 '05 #3
Hi Craig,

I am developing an asp.net application using c# and asp.net 2.0 beta 2. I
started developing this page usign beta1. In beta 1 I have written some code
in Page_LoadComplete(object sender, EventArgs e) events of page. It was
working fine. But after I installed beta 2.0 Page_LoadComplete events is not
firing at all. Can u guide me how can I achieve this goal?

Thankx in advance.
Shailesh.

"Craig Deelsnyder" wrote:
On Tue, 14 Jun 2005 23:15:16 -0500, rodchar
<ro*****@discussions.microsoft.com> wrote:
hey all,

i was wondering what the true/false really does in the
response.redirect("default.aspx", false)?

thanks,
rodchar


It tells the code whether it should keep running to completion after
redirecting the client (run the lines after the Response.Redirect
statement). You can tell the code to keep running the lines after
Response.Redirect, even after the client has received the 302 response for
the redirect. I've never done it for this reason myself, but this
argument comes in very handy if you are doing a Redirect within a
try...catch. By default it would throw an exception to abort the current
thread (which is usually ignored by the framework), but if inside a
try...catch of yours, the exception would get caught by your try..catch
and cause you to think an error happened, when really it's just part of
normal processing (it's how a redirect 'normally' works)...

--
Craig Deelsnyder
Microsoft MVP - ASP/ASP.NET

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

92
by: Reed L. O'Brien | last post by:
I see rotor was removed for 2.4 and the docs say use an AES module provided separately... Is there a standard module that works alike or an AES module that works alike but with better encryption?...
125
by: Sarah Tanembaum | last post by:
Beside its an opensource and supported by community, what's the fundamental differences between PostgreSQL and those high-price commercial database (and some are bloated such as Oracle) from...
7
by: steve bull | last post by:
I have the following code snippet to read the colorRange attributes for the colorRangeSwatch in the xml file listed below. string expr = "/swatches/colorRangeSwatch/colorRange";...
44
by: lester | last post by:
a pre-beginner's question: what is the pros and cons of .net, compared to ++ I am wondering what can I get if I continue to learn C# after I have learned C --> C++ --> C# ?? I think there...
35
by: GTO | last post by:
I do not believe that C# is the future of C++. I also do not believe that adding two thousand new library functions to the standard library is the future of C++. But what is the future of C++? Is...
121
by: typingcat | last post by:
First of all, I'm an Asian and I need to input Japanese, Korean and so on. I've tried many PHP IDEs today, but almost non of them supported Unicode (UTF-8) file. I've found that the only Unicode...
24
by: Bob Alston | last post by:
Most of my Access database implementations have been fairly small in terms of data volume and number of concurrent users. So far I haven't had performance issues to worry about. <knock on wood> ...
21
by: Helge Jensen | last post by:
I've got some data that has Set structure, that is membership, insert and delete is fast (O(1), hashing). I can't find a System.Collections interface that matches the operations naturally offered...
13
by: Jason Huang | last post by:
Hi, Would someone explain the following coding more detail for me? What's the ( ) for? CurrentText = (TextBox)e.Item.Cells.Controls; Thanks. Jason
669
by: Xah Lee | last post by:
in March, i posted a essay “What is Expressiveness in a Computer Language”, archived at: http://xahlee.org/perl-python/what_is_expresiveness.html I was informed then that there is a academic...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.