I got an old Program(class library) developed by .Net 2. Recently I want to use that Program in new project which is use .Net4(For new WPF feature's ). so there is a big problem:
.Net4 don't support System.Web and as result it can't be use Httputility.urldecode!!
So what is urldecode jop? and how can I change that to something, which is support by .Net4?
HttpUtility is wild goose chase for c# users since it's not already there (referenced)
2 alternatives :
string a = System.Uri.EscapeUriString("https://some.url.goes.here"); // for path
string b = System.Uri.EscapeDataString("parameter1=1¶meter2=something"); // for params
Try the UrlDecode method on HttpServerUtility:
System.Web.HttpContext.Current.Server.UrlDecode()
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With