I need to open an URL and download a file from URL. Standard functions, such as InternetOpenUrlW, and native Windows libraries, are using Internet Explorer, but I need to get access to file without Internet Explorer. Moreover, this particular page does not open through IE (but open in different browsers), but it does not matter.
Print("Error in WebRequest. Error code =",GetLastError());
PrintFormat("The file has been successfully loaded, File size =%d bytes.",ArraySize(result));
Error in WebRequest. Error code =5203
It's more than just simplicity!
1. It works independently from any troubles with mt4/5, broker, connection, ticks..
Wrong argumentation, you can have problems with any software and you are always depending of some external conditions. There are no special issue to use WebRequest with MT4/MT5.
2. Some news-server may get into troubles if all around the world try to access the same address at the same tiny moment (the first tick)..
How is it related to the discussion ? It's server side.
3. I find parsing with PowerShell is easier than with mql4, e.g. remove html-tags..
Completely subjective. mql4/mql5 has all possibilities to code anything. Certainly html processing.
4. With wget I am more flexible and I have more options for the download
For sure wget is more powerful than WebRequest. More options, more stability, etc...That's a 20 years old software with a very wide usage, community, etc. But if we talk about HTTP/HTTPS request which are common with WebRequest, what can you do with wget you can't do with WebRequest and mql ?
There are no special issue to use WebRequest with MT4/MT5.
what can you do with wget you can't do with WebRequest and mql ?