John said:
This is all .net stuff and none of it relates to vba/access as far as I can
see.
Regards
The first link was not appropriate - it was C++; I apologize for that but the
second is a valid VB example for HTTP POST.
You can authenticate to a proxy using the WinInet API - specifically the
SetInternetOptions() call:
sUserName = getUserName()
If InternetSetOption(hConnection, INTERNET_OPTION_PROXY_USERNAME, _
ByVal sUserName, Len(sUserName)) = 0 Then
Err.Raise vbObjectError + 511, , "InternetSetOption-U"
End If
sPassword = getPassword() ' set password
If InternetSetOption(hConnection, INTERNET_OPTION_PROXY_PASSWORD, _
ByVal sPassword, Len(sPassword)) = 0 Then
Err.Raise vbObjectError + 512, , "InternetSetOption-P"
End If
There certainly may be other methods especially in .Net but this is a snippet from a
working distribute VB6 app. I chose the WinInet library as a way to avoid controls
and external libraries for distribution reasons preferring to work directly with
the API calls. Using WinInet requires Internet Explorer so its not a perfect solution for
distribution. But it is perhaps one method to consider.
If this intriques you Google WinInet and INTERNET_OPTION_PROXY_USERNAME to find examples.