Server.Transfer problem

mohsenmo

New Member
I am seeing some weird problems with using Server.Transfer especially from inside a normal C# class library. It gives a Thread Aborted error almost as if it got itself in a loop that it couldn't get out of. In many of my pages (not all), it does the same thing outside of a class library in just straight ASP.NET.<BR><BR>However, when I create a pair of extremely basic ASP.NET pages and use Server.Transfer, it works just fine.<BR><BR>By the way, in the pages that don't work, Response.Redirect used in place of Server.Transfer works just fine.<BR><BR>Very odd...In the same class library... are you able to server.transfer to a basic page like one that just displays the word "hello world". Or is it all pages that server.transfer fails? If its the latter I dont know what to tell you. If its the former then I suggest placing breakpoints throughout the script that the abort occurs. If that doesnt work I suggest commenting out sections of code until you can narrow down the code that causing asp.net to abort when using server.transfer. If you find it... then search google and microsoft for answers. <BR><BR>Response.Redirect is very different then server.transfer. Response.Redirect sends a signal to the client and asks the client to request the page. Server.Transfer is done by the server and in fact transfers previous page objects and variables onto the next page.of course you could simply search google for<BR><BR>server.transfer thread aborted :)The only thing I haven't tried is doing a Server.Transfer with a form. Only a simple hello world page. In fact, my pages that work don't have a form on them.<BR><BR>Hmmm...
 
Back
Top