Dim myCred As New NetworkCredential("USERNAME", "PASSWORD") Dim credsCache As New CredentialCache() credsCache.Add(New Uri(Uri), "Basic", myCred) Dim request As WebRequest = WebRequest.Create(Uri) request.Credentials = credsCache
Dim request As WebRequest Dim credidentials As String = "userName" + ":" + "Password" Authorization = Convert.ToBase64String(Encoding.[Default].GetBytes(credidentials)) 'How do I declare Authorization? request.Headers("Authorization") = "Basic " + Authorization
Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.