473,320 Members | 1,969 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

ThreadAbortException on Redirect

Hi !

I am using a httphandler to perform some url rewriting in my
application. My web.config contains the following entry to direct all
urls containing /App/*.ashx to my class AppHandler.cs in namespace
mySite.Web

<httpHandlers>
<add verb="*" path="App/*.ashx"
type="mySite.Web.AppHandler, App_Code"/>
</httpHandlers>

It works perfectly fine in Firefox, but the redirection does not
take place in IE. In IE I get a 404 error - Page cannot be found, and
the address bar contains :

http://localhost/mySite/App/?keyword=mySearchWord

The Debug output showed :

A first chance exception of type
'System.Threading.ThreadAbortException' occurred in mscorlib.dll
An exception of type 'System.Threading.ThreadAbortException' occurred
in mscorlib.dll but was not handled in user code

Based on some suggestions I found in some forums I tried modifying my
Redirect statement in the AppHandler from

context.Response.Redirect(redirectionURL);

to

context.Response.Redirect(redirectionURL,true);

in which case I get the same Debug ouput. If I also enclose this
statement inside a try catch, I get the following Debug output

A first chance exception of type
'System.Threading.ThreadAbortException' occurred in mscorlib.dll
A first chance exception of type
'System.Threading.ThreadAbortException' occurred in
App_Code.k5agqn3f.dll
An exception of type 'System.Threading.ThreadAbortException' occurred
in App_Code.k5agqn3f.dll but was not handled in user code
The thread 0xec0 has exited with code 0 (0x0).

( App_Code is the assembly name for my AppHandler )
WHAT IS HAPPENING ??!! Please help !

Mar 29 '07 #1
0 1610

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

Similar topics

1
by: Naveen Kumar soni | last post by:
Hi we are getting ThreadAbortException error message on one of our .net(1.1) server. The error is get displayed in one of .aspx page, which is having response.redirect statement, if this page is...
1
by: VB Programmer | last post by:
I have a default.aspx page that simply does this (in the "Try" block): Response.Redirect("MyStartPage.aspx") I keep getting this exception on this line: "System.Threading.ThreadAbortException:...
3
by: Steve - DND | last post by:
I just implemented a page that performs a Response.Redirect(url, true). As such, I wrapped it in a try catch, and explicitly caught a ThreadAbortException. However, the thread abort exception was...
4
by: splap20 | last post by:
Every day a large chunk of XML is posted up to my app via http. The app interprets this XML and writes results to a SQLServer. Occasionally a ThreadAbortException is thrown during this process....
1
by: Eric | last post by:
I have the following situation: I was getting intermittent errors using Reponse.Redirct("url", true) and was trying to catch the ThreadAbortException, but it was not staying caught and was showing...
4
by: Christoph Wienands | last post by:
Hey guys, I just got some really weird behavior. I put the following code into the Application_Start event in Global.asax: // init some trace listeners Uri codeBase = new...
3
by: =?Utf-8?B?RXRoYW4gU3RyYXVzcw==?= | last post by:
Hi, I am running a web service which sometimes throws exceptions. I have a lot of error trapping within the web service, but I have missed the current problem. I am working on the current issue,...
5
by: dorrit.Riemenschneider | last post by:
I've developed a sharepint webpart (ASP.NET 2.0 application) with use of the CrystalReportViewer web control (CrystalDecisions.Web.CrystalReportViewer). All works fine except the export of the...
1
by: mwallis76 | last post by:
Upon clicking on a hyperlink generated in a ASP.NET GridView control, I am finding Firefox 1.5 to crash. However, when clicking on the same link, Internet Explorer 6.0 works just fine and is...
2
by: Zeba | last post by:
Hi ! I am using a httphandler to perform some url rewriting in my application. My web.config contains the following entry to direct all urls containing /App/*.ashx to my class AppHandler.cs in...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

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.