URLencode a URL Query string

I

Imran Aziz

Hello All,
from my C# dialog based application I am creating a URL that has some
query string parameters that I want to URL encode, the URLEncode function is
suppose to be in the HttpUtility class under System.Web but I cannot seem to
find it, is there an alternate to encode a URL query string in C#?

Imran.
 
G

Guest

HttpUtility is under System.Web, u have to include it in ur project..ie

using System.Web,

u also have to add the dll itself as a refernce into ur project..ie on the
Reference Folder (under the Solution explorer) right-click, add reference,
and its in the list.

once u do both steps, then u have access to HttpUtility.urlEncode()

Hope this helps
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top