UriBuilder.Fragment Property gets or sets the fragment portion of the URI.
Imports System.IO
Imports System.Net
Imports System.Text
publicclass MainClass
Shared Sub Main()
Dim uBuild As New UriBuilder("http://www.yourDomain.com/")
uBuild.Path = "index.htm"
uBuild.Fragment = "main"
Dim myUri As Uri = uBuild.Uri
End Sub
End Class