What is difference between Server.transfer and
Response.redirect ?
Answers were Sorted based on User's Feedback
Answer / sri
server.trasfer directly transfer the execution of a page to
another page without taking the client into the
picture.while response.redirect sends the response to the
client browser and directs him to make a request to call a
page( called round trip).it is better to use
server.transfer when you do not want to execute code on
client.
| Is This Answer Correct ? | 29 Yes | 5 No |
Answer / hema
Server.Transfer redirects directly to the new url. It does
not take a round trip. where as response.redirect tells the
client to make a request to the new url. this takes a round
trip. so it takes so much time. so server.transfer is
better when compared to response.redirect
| Is This Answer Correct ? | 17 Yes | 4 No |
Answer / yugandhar reddy
Request.Redirect tranfers the user to the new page.The new
page can be in the same application or outside the
application.Browser upgradation of new url i.e round trip
to client takes place.It cannot take the current form
control values to the new page byitself.using querystring
only it can take.
ex: Request.Redirect("Default2.aspx");
where as Server.Transfer redirects to the new page that
should be present in the same application.single trip takes
place i.e no browser upgradation of new url.It can take
current for control values to the new page using
preserveform attribute.
ex : Server.Transfer("Default2.aspx");
| Is This Answer Correct ? | 9 Yes | 0 No |
Answer / hema
Server.transfer transfers to a page on the server only
whereas response.redirect redirects to any page. In
server.transfer, the new URL is not displayed. whereas in
response.redirect the new url is displayed.
| Is This Answer Correct ? | 10 Yes | 2 No |
Answer / kiran kumar
Server.Transfer: - This redirects the client with in the
same application ie, from one ASP page to other ASP page
with in the application. This will not update the history.
Response.Redirect: - This redirects the client to the other
URL ie, from one ASP page to other applications page. This
will update the history.
| Is This Answer Correct ? | 7 Yes | 1 No |
Answer / rj
without query string we can access previous page control
values in server.transfer method. Round trip not allowed
In the response.redirect method using query string we can
access the previous page controls values. Round trip allowed
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / khaleek ahmad
1) In Response.Redirect previous page is not accessible
while in Server.Transfer it is optional.
Server.Transfer(URL,bPreserveForm);
2) Server.Transfer use only within the server.But
Response.Redirect can be use ouside the server.But it should
be a full path.
For more detail please see at
http://interview-preparation-for-you.blogspot.com/2010/12/difference-between-servertransfer-and.html
| Is This Answer Correct ? | 0 Yes | 1 No |
Can any body send me Some Interview Questions of ASP.Net 2.0 or Later to my mail id that is gauravscott@gmail.com
Explain the difference between a namespace and an assembly name?
What is the order of execution for an ASP application?
what is stored procedural
which property will make a control span an entire site office parent class
Destructors CANNOT be implemented in which one of the following?
What are server variables collection?
What are the asp objects?
What is an asp program?
What is application object in asp?
What is the difference between asp and acp?
difference between SAP R/2 and R/3