Forum

Override WebRequest default headers

Is there a way to override the WebRequest headers added by default, such as Accept-Language? The default value for Accept-Language, I suppose, depends on the system locale, so for me it's ru,en;q=0.5 which means ru locale with weight 1 and en locale with weight 0.5 . My goal is to get a response

Reading from a pipe via ReadFile [WinAPI]

Trying to run cmd.exe as a child process and read standard output from it, but the ReadFile function results in error 109 (ERROR_BROKEN_PIPE). What am I missing here? #define BUFFER_SIZE 16 #define ERROR_MORE_DATA 234 #include <WinAPI\sysinfoapi.mqh> #include <WinAPI\processthreadsapi.mqh> #include