Both methods calls Response.End method internally ends the page execution. Then executes Application_EndRequest event in the application's event pipeline and hence the line of code that follows Response.End is not executed which is raising the exception.
To overcome this just disable Response.End in both methods as follows :-
Server.Transfer(Request.FilePath);
Response.Redirect(Request.FilePath);
to
Server.Execute(Request.FilePath);
Response.Redirect(Request.FilePath,false);
Computers are composed of nothing more than logic gates stretched out to the horizon in a vast numerical irrigation system.
Stan Augarten
The article is so informative. This is more helpful. Thanks for sharing.
ReplyDeletebest software testing training institute in chennai with placement
selenium course
software testing training institute
i have read it's very nice and wonderful thanks for it web design company in velachery
ReplyDelete