i

ASP.Net A Complete Guide

HttpUtility Class

This class provides a method for URL encoding. The URL encoding will help in encoding the item of the query string. In the URL, there is a need to provide the code to separate the URL from query string with a '?'. We can separate the query string item with the symbol '&.'

Below is the Example of HttpUtility:

 Dim query As String = "Name=" & _

 HttpUtility.UrlEncode (txtName.Text) 

 Response.Redirect ("Details.aspx?" + query)