I am trying to redirect to the same page with different query string parameters
HttpResponse resp = HttpContext.Current.Response;
开发者_开发技巧
resp.Redirect(landingPagePath)
To avoid further processing after redirection i check if
HttpContext.Current.Session.IsNewSession == false
but for some reason i found that this is not always the case after redirection
can anyone please tell why is this happening
Thanks
Why don't you use your Page.IsPostBack
flag instead? It will be false when you redirect the page back on itself with the modified querystring.
If you are trying to avoid further processing (your description is vague), maybe you could pass an additional parameter to indicate that you just redirected.. and determine what to do based on the value of that parameter..
精彩评论