MT4 - Java comminication of data.

 

Hey, I'm want the MT4 terminal to feed price data into an external program through an EA, the external program will then carry out calculations and feed buy/sell instructions back into the terminal. Which would be a better language for the external program, c++ , c# or java? I'm asking the question concerning comparatives purely from a suitability perspective.

 

Would I need to use named pipes or would I need to use DLLs? 

 

I've read some documentation on DLLs, and I will continue reading.

 
Luciano Ola:

Hey, I'm want the MT4 terminal to feed price data into an external program through an EA, the external program will then carry out calculations and feed buy/sell instructions back into the terminal. Which would be a better language for the external program, c++ , c# or java? I'm asking the question concerning comparatives purely from a suitability perspective.

 

Would I need to use named pipes or would I need to use DLLs? 

 

I've read some documentation on DLLs, and I will continue reading.

Would it be slower if I had the mt4 write to a file and read from a file being manipulated by the c++/c#/java program or would that be a suitable approach?
 
Luciano Ola:
Would it be slower if I had the mt4 write to a file and read from a file being manipulated by the c++/c#/java program or would that be a suitable approach?

Exchanging complete data every tick using named pipes (or files) is not a bright idea. Instead you should exchange large sets of trading data by sharing a memory reference.

If you ask, which PL is "better", then it is the one you know better. However the c++ is the most supported one in MT4.

 
Ovo Cz:

Exchanging complete data every tick using named pipes (or files) is not a bright idea. Instead you should exchange large sets of trading data by sharing a memory reference.

If you ask, which PL is "better", then it is the one you know better. However the c++ is the most supported one in MT4.

Thank you for the response, when you say memory reference are you referring to pointers in mql4 and pointers I'm c++? 
 
Luciano Ola:
Thank you for the response, when you say memory reference are you referring to pointers in mql4 and pointers I'm c++? 
You may pass variables and arrays as references to the DLL, which is exactly what you need. You may also use pointers if you need them for some reason, however they are not supported by MQL in DLL calls and some workaround would be necessary.
 
Ovo Cz:
You may pass variables and arrays as references to the DLL, which is exactly what you need. You may also use pointers if you need them for some reason, however they are not supported by MQL in DLL calls and some workaround would be necessary.
Thanks, just want to stress that I'm not communicating functions, just values. 

The external program will, in the long run, have to run for multiple instruments, but not for the purpose of cross currency analysis, every instrument wl be independent of the other.

Alright so the DLL  store references, memory references. I guess I'll have to read up on that, is there documentation specifically addressing this on the MQL sight. So far I've only found DLL information under imports.