Ispostback

  • Thread starter Thread starter Mathana g
  • Start date Start date
M

Mathana g

Hi,

I am getting Ispostback property value as true even the page loads very
first time(used Server.Transfer for navigation)
Even I tried with
Request.Url.AbsolutePath != Request.UrlReferrer.AbsolutePath


also. But could not solve the problem
 
Hi Mathana,

If you use Server.Transfer, you will always get the IsPostback = true. Try
using Response.redirect.

When you are using Server.Transfer, the client considers it as the Original
Url even though the content is of some other page. You can observe the same
by looking at the Address bar or your browser. i.e. the URL does not change.
But if you use Response.redirect you can see the URL changing.

Visit the following link to understand more about server.transfer

http://www.csharpfriends.com/Articles/getArticle.aspx?articleID=15

happy programming!!
pradeep_TP
 
Back
Top