27 August 2013

Response.Write Vs Response.output.write()
Simply Response.write() is used to display the normal text and Response.output.write() is used to display the formated text.
Example:
Response.Output.Write(".Net{0},"ASP"); // Its write
Response.Write(".Net{0},"ASP"); // Its Wrong
Response.Redirect Vs Server.Transefer
1.Response.redirect sends message to the browser saying it to move to some different page while Server.transfer does not send any message to the browser but rather redirects the user directly from the server itself.So in Server.transfer their is no round trip while Response.redirect has a round trip hence puts a load on the server. 
2.Using Sever.transfer you cannot redirect to a different server itself while using Response.redirect you can redirect to a different server also. 
3.With Server.transfer you can preserve your information.It has a parameter called as "preserve form",so the existing query string etc will be avilable in the calling page.This is not possible in Response.redirect 
Response.Redirect() Vs  Response.RedirectParmanent()
Response.Redirect() :
Search Engine will take this redirection as Temporary(Status 301) and always keep first page in its cache. 
Response.RedirectParmanent() : 
Search Engine will take this a permanent redirection(Status 302) and will remove first page from its database and include second page for better performance on search. 
Useage: 
Response.Redirect used when your page is temporarily changed and will again be reverted to original within a short time. 
Response.RedirectParmanent() when you are thinking of deleting the original page totally after the search engines changes its database.