Is it possible for one source file to screen multiple currency pairs simultaneously?

 

So, I have a strategy that I want to implement on EA and it will be a while loop based strategy such that the program will reiterate calculations

until the profitable condition is met, then will execute the appropriate orders.

Would it be possible for one file to reiterate those calculations on all currency pairs ?

What I need is sort of like as if there are multiple programs for each currency pair working independently

what bothers me is that if I include such profitable conditions for all currency pairs within that while loop condition, then the program wouldn't screen the remaining currency pairs as it executes the OrderSend() function

How would I go about solving this problem?



Also, can anyone clarify the OrderClose function? I understand there needs to be a ticket number or a reference to it for OrderClose but how would I go about finding it?

Also, the while loop condition for OrderSend will either execute long position on a currency OR a short position on a currency depending on the condition

so how would I go about finding out whether it was a long position or a short position?

 
qudcjf7928:

So, I have a strategy that I want to implement on EA and it will be a while loop based strategy such that the program will reiterate calculations

until the profitable condition is met, then will execute the appropriate orders.

Would it be possible for one file to reiterate those calculations on all currency pairs ?

What I need is sort of like as if there are multiple programs for each currency pair working independently

what bothers me is that if I include such profitable conditions for all currency pairs within that while loop condition, then the program wouldn't screen the remaining currency pairs as it executes the OrderSend() function

How would I go about solving this problem?

Also, can anyone clarify the OrderClose function? I understand there needs to be a ticket number or a reference to it for OrderClose but how would I go about finding it?

Also, the while loop condition for OrderSend will either execute long position on a currency OR a short position on a currency depending on the condition

so how would I go about finding out whether it was a long position or a short position?

Send me your source file, I have done this successfully once before.

Or

Post it as a job in the freelancer section  

Or

Send me a personal message so I can remember to illustrate how I achieved this in the past

 
Dafiri Irimagha:

Send me your source file, I have done this successfully once before.

Or

Post it as a job in the freelancer section  

Or

Send me a personal message so I can remember to illustrate how I achieved this in the past

Problem solved. So far, I simply decided to include all currency pairs for screening within a single while loop condition thus trading one currency at a time as opposed to multiple at a time

(When I backtested it, the probability of profitable conditions on multiple currencies occurring simultaneously is low enough that I can simply trade one currency at a time)

Also, as for OrderClose function, I just let boolean variable equal to the corresponding OrderSend and used that variable as part of the ticket number

Reason: