Dukascopy
 
 
Wiki JStore Search Login

IChart and drawing IChartObject
 Post subject: IChart and drawing IChartObject Post rating: 0   New post Posted: Wed 03 Oct, 2012, 21:25 
User avatar

User rating: 7
Joined: Fri 13 Jan, 2012, 20:49
Posts: 94
Location: Poland, Warsaw
Hello Dear Support,

Let's say I have opened a chart and created following IChartObject in Standalone API:
IChartObject obj = chart.getChartObjectFactory().createHorizontalLine();
Now, I would like to click left mouse somwehere on the chart and place the obj on it. Is there, in Standalone API, a method allowing me to do that?

I know there is a method
chart.addToMainChart(obj)
but in such case I need to determine the price before I call the method.

If there is no such method are you planning to add something like this to your API?

And one last question - could you please advice how to add mouse action listener to the IChart ?

Thanks in advance and best regards,
Kurak


 
 Post subject: Re: IChart and drawing IChartObject Post rating: 0   New post Posted: Thu 04 Oct, 2012, 15:34 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
At the moment the best you can do is to plot the chart object on the center of the chart and then manually move it. See:
https://www.dukascopy.com/wiki/#JForex_SDK/Add_chart_objects


 

Jump to:  

  © 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