Is this possible?

I would like to run 3 different EA’s on the 1 hour EURUSD pair on the same Aplari demo account. Is this possible? How can I do it?

Thanks

Yes its possible. You need to allocate a unique magic number to each EA. Check out the MQL help file.

You basically need to include a unique magic number in the arguments passed to the trade open fuction when the EA opens a trade. That associates these trades with a particular EA

You can then need to make sure that each EA manages only its own trades (identified by the magic number), and ignores trades placed by other EA’s.

There are 1001 examples available, and most EA’s you’ll find on forums already work this way (unfortunately the examples provided by metaquotes dont !)

open 3 charts of 1-hour EURUSD, put an EA on each, and set magic number to be different so that the EA’s can each identify their own trades.

Many thanks for your help.

Is their any limit on the number of different Magic Numbers I can run?

If I run different E A’s with different Magic Numbers is their any way I can look at the “Save as Report” and distinguish which E A did what?

Thanks again

I also want to know the answer to this please.

Best Regards,
Matt Jones .

Magic numbers can run into the thousands.

Don’t know about your question about report though. I hope somebody else can answer that for you.

You can write an indicator or script to export the trade history, and include the magic number in the data being written. If your demo trading its probably sensible to do this anyway because demo accounts tend to expire, and if your serious about testing, you’ll probably want to retain an independant copy of your trade history.

I’m not sure about the magic number being included on the report, IIRC some data is incuded in the HTML as hidden fields, although its years since I last looked.

Does the full report include comments ?, if so you could always set the comment parameter to equal the magic number

I guess you can’t use the magic no. for reports, but you can just copy the no. or define whatever you like to the commentary field and this can be selected to show up in reports.