I have created an ASP.NET class.
In that class i would like to use the Server.UrlEncode.
Why intellisense is not helping me at all and instead of Server.UrlEncode it displays the HttpServerUtility?
I have already a reference to system.web
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can access that function through the HttpContext object. I guess your class is in a class library in which you should always check you have a context in case your code is called outside of a web context. Try this: