Thread: How to code?
View Single Post
  #1068 (permalink)  
Old 07-04-2008, 09:55 AM
amatrader amatrader is offline
Junior Member
 
Join Date: Dec 2007
Posts: 13
amatrader is on a distinguished road
Hi there,

I hope you don't mind me butting in here, I'm looking at a similar situation and I have a thaught on the issue... what about if you code a loop at the end of your program that says "if no order is open run through again". and let it loop maybe 3 or 4 times.

If it does that then any missed orders (which happens quite often) should surely get picked up. or is there something wrong with my thinking.

I think it would look something like this...

Quote:
for (int k = OrdersTotal() ==0; k >=2; k++)
{
if ( ! OrderSelect ( k, SELECT_BY_POS, MODE_TRADES ))continue;
if (k > 2) break;
}


return(0);
}
I'm still new to this so if it doesn't make sense please explain to me why.
Reply With Quote