Click here to Skip to main content
15,887,683 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Unable to redirect to another page I get "Internet Explorer cannot display the webpage" error while redirecting to another page.

Default.aspx :

MIDL
string targetURL = "~/Result.aspx?Xresult=" + HttpUtility.UrlEncode(response);
      Response.Redirect(targetURL);


Thanks in advance.
Posted
Comments
TweakBird 4-Mar-11 15:04pm    
Are tried in google?

string targetURL =Page.ResolveClientUrl("~/Result.aspx?Xresult=" + HttpUtility.UrlEncode(response));
Response.Redirect(targetURL);


If i misunderstand your question, please feel free to correct me.
I hope the above information will be helpful. If you have more concerns, please let me know.
 
Share this answer
 
Comments
maadhukari 4-Mar-11 16:38pm    
Thanks Monjurul. But that didn't solve my problem.
Monjurul Habib 5-Mar-11 3:01am    
can you please share what kind of value you are trying to pass using "response" parameter ?
sairam.bhat 5-Mar-11 3:45am    
Good answer
Are you calling System.Web.HttpUtility.UrlEncode?

It is required.
 
Share this answer
 
Comments
sairam.bhat 5-Mar-11 3:49am    
good answewr
You should do like this,
string targetURL = "~/Result.aspx?Xresult=" + HttpUtility.UrlEncode(response);
 Response.Write("<script> window.open(targetURL); </script>");



Hope be Helpful,
Theingi Win
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900