One method is to have a bool function to check if the period is between London open and London close.Originally Posted by ;
Create some input factors so it's possible to alter the London hours as required:
Inserted Code enter LonOpen=8; // London Open (broker time) enter LonClose=17; // London Close (broker time)
Add the job:
Inserted Code bool London() if(Hour()gt;=LonOpen Hour()lt;LonClose) return(true); return(false);
Before launching an order, simply check the return value of London()
Inserted Code if(London()... ) {
This depends on what you mean with per day. Do you mean that a 24 hour interval, or profit produced between London open and London near?Originally Posted by ;
How do you want to take care of orders that were opened after London open but did not shut until after London shut (or maybe even after the next London open)?
Can it be time the order started or the period the order closed that is significant to you?