Hi Is there any way this would work if I just used "WinINet/1.6" for user agent as I am using this in mt4 and the only part not working is:
TerminalInfoString(TERMINAL_OS_VERSION)," TerminalInfoString(TERMINAL_CPU_NAME),
Since MQL4 does not support those constants.
I tried changing it to following but to no avail.
Hi Is there any way this would work if I just used "WinINet/1.6" for user agent as I am using this in mt4 and the only part not working is:
TerminalInfoString(TERMINAL_OS_VERSION)," TerminalInfoString(TERMINAL_CPU_NAME),
Since MQL4 does not support those constants. I tried changing it to following but to no avail.string GetUserAgent() { return StringFormat( "%s/%d (%s; %s; %s %d Cores; %dMB RAM) WinINet/1.6", TerminalInfoString(TERMINAL_NAME), TerminalInfoInteger(TERMINAL_BUILD), "Windows NT 10.0; Win64", TerminalInfoInteger(TERMINAL_X64) ? "x64" : "x32", "amd64", TerminalInfoInteger(TERMINAL_CPU_CORES), TerminalInfoInteger(TERMINAL_MEMORY_PHYSICAL) ); }
any help is highly appreciated thanks alot.