Proxy Authentication error
I have a connection made to the internet :-
remoteFile = session.OpenURL(urlPath, 1 ,
AfxMessageBox("Received Exception from OpenURL()");
// Handle exception
This all works fine, and then I wish to download the file using :-
if (remoteFile == NULL)
cout << "Error in OpenURL";
cout << "Ok in OpenURL";
// Read from file
while (nBytesRead = remoteFile->Read(inBuf, sizeof(inBuf)))
When I run the software at home all works fine and the file (Excel) is downloaded successfully.
However, at work I'm getting Proxy Authentication error, i.e. the software cannot go out through the gateway.
The Windows Administrator tells me that if I can type the URL in IE browser and a pop-up comes up with Save As, Open etc, and later the file is downloading, then it must be my process. However, as I said this works at home ok.
Also, I should mention that when I use the same process at work (or home) to point to URLs ending with .html (obviously no dialog boxes appear), then all ok.
FYI: whether I try to download the file manually or using the automated process - in both cases I'm logged to the server as the same user who has permissions to download files from the Internet.
Any ideas what it might be ? Is OpenURL, or remoteFile->Read works differently from html to Excel files ?
Last edited by ami; 09-06-2009 at 02:02 PM.
you need to also give your proxy username and proxy password to your call
INTERNET_PORT nPort = INTERNET_INVALID_PORT_NUMBER,
LPCTSTR pstrUserName = NULL,
LPCTSTR pstrPassword = NULL
Your browser might be configured to take this automatically...
Life is a short warm moment -
Death is the long cold rest.
By vrijdag in forum VB Classic
Last Post: 12-30-2006, 05:43 AM
By Khalizan in forum VB Classic
Last Post: 11-28-2001, 01:32 AM
By Andrew McLellan in forum Java
Last Post: 05-09-2001, 05:34 PM
By Chris.G in forum VB Classic
Last Post: 11-13-2000, 03:16 PM
By Murray Foxcroft in forum Web
Last Post: 11-02-2000, 02:42 AM
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center