I am implementing Front Controller in ASP.net as outlined in Microsoft documentation titled "Implementing Front Controller in ASP.NET Using HTTPHandler" (http://msdn.microsoft.com/library/de...ollerInASP.asp
Everything works well except for context.server.transfer(string url) method (refer to RedirectingCommand.cs class in the above documentation)
Here are the error details
Server Error in '/DCT' Application
-------------------------------------------------------------------------------
Error executing child request for /DCT/WebUI/Labor/test.aspx.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.HttpException: Error executing child request for /DCT/WebUI/Labor/test.aspx
Source Error:
Line 18: public void Execute(HttpContext context
Line 19:
Line 20: context.Server.Transfer("/DCT/WebUI/Labor/test.aspx")
Line 21:
Line 22:
Source File: c:\inetpub\wwwroot\dct\architecture\redirectingcom mand.cs Line: 20
Stack Trace:
[HttpException (0x80004005): Error executing child request for /DCT/WebUI/Labor/test.aspx.
System.Web.HttpServerUtility.ExecuteInternal(Strin g path, TextWriter writer, Boolean preserveForm) +170
System.Web.HttpServerUtility.Transfer(String path, Boolean preserveForm) +2
System.Web.HttpServerUtility.Transfer(String path) +7
DCT.Architecture.RedirectingCommand.Execute(HttpCo ntext context) in c:\inetpub\wwwroot\dct\architecture\redirectingcom mand.cs:2
DCT.Architecture.Handler.ProcessRequest(HttpContex t context) in c:\inetpub\wwwroot\dct\architecture\handler.cs:2
System.Web.CallHandlerExecutionStep.Execute() +17
System.Web.HttpApplication.ExecuteStep(IExecutionS tep step, Boolean& completedSynchronously) +8
-------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:1.0.3705.288; ASP.NET Version:1.0.3705.288
NOTE
-------
1) I executed the application in .NET Framework Version 1.1, and still get the same exact error
2) I searched in knowledge forums, and realized that this is a very common error
3) The application works fine if I use context.Response.Redirect("/DCT/WebUI/Labor/test.aspx"); instead of context.Server.Transfer("/DCT/WebUI/Labor/test.aspx"); method. But I need to use Transfer method, as I have to pass some objects from page1 to page2
Please let me know the possible solutions, and if there are any patches available to correct this problem