Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Orders with GoodTillTime
 Post subject: Orders with GoodTillTime Post rating: 0   New post Posted: Wed 02 Dec, 2009, 14:06 

User rating: 0
Joined: Fri 27 Nov, 2009, 16:30
Posts: 3
Hi there,

I'm trying to submit order and then set up its GTT time using this code:

if (condititions == true) {
order = engine.submitOrder(getLabel(instrument), instrument, IEngine.OrderCommand.BUYSTOP, lot,
prixBuy, 0, prixBuy - (stopLoss * pip), prixBuy + (takeProfit * pip));
calendar.setTimeInMillis(tick.getTime()+360000);
order.setGoodTillTime(calendar.getTimeInMillis());
}

But it doesn't work and I'm getting this error:Order should be "place bid" or "place offer.

Could you please help me with this.

Thanks
Ondrej


 
 Post subject: Re: Orders with GoodTillTime Post rating: 0   New post Posted: Fri 04 Dec, 2009, 09:43 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Hello,
GoodTillTill is only supported for place bid/place offer orders


 

Jump to:  

cron
  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com