multiple instances

 
If I am running multiple instances of MetaTrader and one is logged into a demo and the other a live account, can I use an EA on the demo to set a globalvariable that my live account EA will recognize? I thought this might work as they are running from the same terminal on the computer???? Any info/confirmation would be greatly appreciated! Thank you forum..... Daniel
 
forexman05:
[...] as they are running from the same terminal on the computer???? [...]

But they are not... To have 2 Terminals running at the same time u must install 2 instances of MT4, each in it's own directory.

Here is a good list of possible solutions to your problem by 7bit -> https://www.mql5.com/en/forum/128440.

 
gordon:

But they are not... To have 2 Terminals running at the same time u must install 2 instances of MT4, each in it's own directory.

Here is a good list of possible solutions to your problem by 7bit -> https://www.mql5.com/en/forum/128440.


Thank you! Unfortunately, that gets a little above my head-I am not a programmer. I have tried to learn mql and use this forum to "borrow" good code and ideas and then make the code do what I want it to :) I truly appreciate your feedback!
 
GlobalVariable will not work across different MT4 instances. You need some form of communication (file, message, DLL) between between different MT4 instances.
 
forexman05:
If I am running multiple instances of MetaTrader and one is logged into a demo and the other a live account, can I use an EA on the demo to set a globalvariable that my live account EA will recognize? I thought this might work as they are running from the same terminal on the computer???? Any info/confirmation would be greatly appreciated! Thank you forum..... Daniel

save the parameter in a text file
Reason: