Need to help with "tradehour"

User avatar
fxdaytrader
Trader
Posts: 190
Joined: Sun Jun 10, 2012 7:03 am
Location: Poon-Town (germany, se-asia, se-europe) ...

Re: Need to help with "tradehour"

Post by fxdaytrader »

ROOI wrote: Yip.Got it to open trades.Works well.The problem is it open a hedge trade every tic for that minute that is "trading hours" are on.So its like a little to many stacked orders.

IS there anyway to change that it executes once per trading interval ?
Now it is doing the following:

When it is inside tradingtime, it will check if there already exists a BUY and a SELL order.
If either not exists, it will open one. So there are never more than one buy and one sell order at the same time opened.

For example: if one buy already opened, it will open just a sell order.
You do not have the required permissions to view the files attached to this post.
User avatar
ROOI
Trader
Posts: 15
Joined: Thu Sep 19, 2013 2:49 pm

Re: Need to help with "tradehour"

Post by ROOI »

Thanks you fxdaytrader.Will have a look at it today.

You have been a great help and a gentlemen
Just thankful to be alive and to be able to learn. I'm a trader slowly learning to code and I apologize in advance for the stupid questions.I always try to find the answer myself before asking for help.
Post Reply

Return to “Coders Hangout”