Hi all and thanks for taking the time to read this. I have a c# application where I wish to override the default WinInet cookie settings. The goal is that even when the system WinInet cookie privacy settings are set to Block All, within my process, cookies will still be accepted calls. Reading the documentation, it looked straightforw...
I have a piece of software running on a remote device which calls InternetDial to establish a connection and report information.
Most of the time this works fine, but occasionally, some sort of error will occurr (bad signal etc.) and despite calling the function with INTERNET_AUTODIAL_FORCE_UNATTENDED, windows still appears to pop up di...
Our application uses WinInet to download data from a web server that supports Windows Authentication (Negotiate). However, when Internet Explorer's Windows Authentication setting is disabled, we only get an HTTP 401 - Unauthorized error.
Both .NET's WebClient and the newer WinHTTP don't show this behaviour, but they are not a feasible o...
I'm using WinInet to connect and retrieve information from one of our server. I'm using the following:
indexdata: array of byte[1..5000] of byte;
infoBuffer: array [0..5000] of char;
BufferSize: DWORD;
reserved: DWORD;
text: string;
BufferSize := Length(infoBuffer);
res := HttpQueryInfo(hHttpRequest, HTTP_QUERY_RAW_HEADERS_CRLF, @inf...
CFtpFileFind finder(mConnection);
found = finder.FindFile("*.log");
while (found)
{
found = finder.FindNextFile();
wsprintf(fileInfo, "%s", finder.GetFileName());
//need file size of this .log
//no member function for this in CFTPFileFind class?
}
EDIT Answer
finder.GetLength();
...
I am trying to simply access a page using the WinInet APIs. Once I access it, I'd like to be able to read the contents into a string. I've already initialized the root node. Here's what I got so far:
HINTERNET hChildURL = InternetOpenUrl(hInternetRoot,
LPCTSTR(CString("http://www.google.com/")),
...
Sorry for such a long question. It's just I've spent several days trying to solve my problem, and I'm exhausted.
I'm trying to use WinINet in an asynchronous mode. And I must say... this is simply insane. I really can't understand this. It does so many things, but unfortunately its asynchronous API is so much poorly designed that it jus...
I am getting crashes deep in wininet.dll.
It crashed trying to read the zero memory location in HTTP_REQUEST_HANDLE_OBJECT::ReleaseConnection
Is this a bug in the actual DLL and not caused by improper usage?
wininet!HTTP_REQUEST_HANDLE_OBJECT::ReleaseConnection+0x60
wininet!HTTP_REQUEST_HANDLE_OBJECT::CloseConnection+0x84
winin...
Hi
I am having issues setting the proxy username and password with wininet.
The bellow code set the proxy but the username and password fails with error code "12018"
[DllImport("wininet.dll", SetLastError = true)]
private static extern bool InternetSetOption(IntPtr hInternet, int dwOption, IntPtr lpBuffer, int lpdwBufferLength);
...
I'm curious why I'm having trouble with this function. I'm downloading a PNG file on the web to a destination path. For example, downloading the Google image to the C: drive:
netDownloadData("http://www.google.com/intl/en_ALL/images/srpr/logo1w.png", "c:\file.png");
The file size is correct after downloading. Nothing returning false. W...
Hello All!
I'd like to download a file from my Delphi program in a separate thread dedicated to the download.
The problem is that the main program can be closed any time (thus the download thread can be terminated any time as well). So even if there is no connection or the server lags for precious seconds I need a way to terminate the ...
I've seen several articles on how wininet can force a web browser control to start a new session (the equivalence of opening IE, going to File and then clicking New Session).
Is this correct or am I misunderstanding? If it is possible, could someone point me in the direction of the reference material(s) that could get me started with it...
Hey people,
I have to do some HTTP interaction, which I relied on my own WinInet class so far.
Now it comes to handling JS.
I have to work with a site that requires JS.
No way around it.
So what would you suggest for C++ HTTP + JS interaction? I would love something like mechanize (perl, python, etc), that makes whole form interactio...
I see that WinHTTP is not reentrant (1,2). Is WinINET reentrant?
We have an ActiveX control that does synchronous HTTP with WinINET. If the browser (in javascript) fires an asynchronous http request (ajax) and then immediately calls the ActiveX operation (same IE process), it seems like the two operations are interleaving, perhaps reent...
I'm using http://stackoverflow.com/questions/434469/how-to-clear-system-windows-forms-webbrowser-session-data/1871828#1871828 and it works as long as there is only one browser. Is it possible to give 2 web browser controls within the same application their own session?
If so, would I just need to change
InternetSetOption(IntPtr.Zero, I...
I don't have very much information to work with here, yet. Our app sends an HTTP query to our server, and in all the cases we've used until now it has worked fine. But for one client, whose network goes through a proxy, their logs indicate that the request goes out successfully, but no reply ever returns, and our web server shows nothi...
Hi,
The internet access code in our product works perfectly for 99.99% of people. However, for a few of them, it just doesn't work at all. We've been adding some trace code to try and figure out what the problem is, and it it turns out that InternetOpenURL is reporting error 2 - "The system cannot find the file specified" - from this fu...
A part of my program uses WinInet's caching function (e.g. FindFirstUrlCacheEntry, FindNextUrlCacheEntry) to go through the system cache and delete files that meet certain criteria.
The problem is that when a large file is found in the cache, FindNextUrlCacheEntry fails with ERROR_INSUFFICIENT_BUFFER, and requests an unreasonable buffer...
I'm writing a client app that continuously polls my server for updates.
I'm using c++ wininet. Are there any tips on how to minimize request time? Are there any flags I should use to these methods, http headers I should set, what handles should I reuse?
while(true)
{
InternetOpen();
InternetConnect();
HttpOpenRequest();
H...
I don't know what happened in hour My script stopped to retrieve data from internet instead it is still able retrieve data from http:// localhost/ .
The wininet error I got is 12029 (ERROR_INTERNET_CANNOT_CONNECT) - as listed here http://support.microsoft.com/kb/193625,
The code which produces error is:
HINTERNET hOpenUrl = InternetOp...