ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Mouse over Bar and view other OHLC timeframe (picture-in-a-picture)?
Posted by chuck on Jul-08-2020 00:35
Peter,

Inquiring your input... I have a 15m OHLC Chart, I would like to Mouse-Over any 15m Bar on the Chart and reveal (in some sort of dynamic form/window) the corresponding DateTime of the 1m Chart of the Bar I am hovering over. Sort of like a “picture in a picture” that is dynamically generated.

Rather than reinventing this, inquiring if Chart Director supports something like this or similar and if so, do you have a VB.NET example?

Thanks Peter!
Chuck

  Re: Mouse over Bar and view other OHLC timeframe (picture-in-a-picture)?
Posted by Peter Kwan on Jul-08-2020 19:26
Hi Chuck,

Basically, you just need to draw a 1 minute bar chart in some kind of mouse event, and then display it somewhere. The exact code depends on the exact behaviour you want.

Consider the "Finance Chart Track Line" sample code:

https://www.advsofteng.com/doc/cdnet.htm#trackfinance.htm

In the above example, the MouseMovePlotArea is used. In the event handler, the code draws the some text with the data of the current candlestick, and display it on top of the plot area as the legend box as a dynamic layer. You can draw another candlestick chart using 1 min data, and display it prefer you like.

I think you already know how to draw a candlestick chart. To display it in a dynamic layer, use:

' display myCandleStickChart at (x, y) of the dynamic layer (d = drawarea of dynamic layer)
d.merge(myCandleStickChart.makeChart3(), x, y)

Hope this can help.

Regards
Peter Kwan

  Re: Mouse over Bar and view other OHLC timeframe (picture-in-a-picture)?
Posted by chuck on Jul-08-2020 21:02
Thank you Peter, I will review.
Best,
Chuck