Features of Google Finance Charts

TeeChart for Java (NetBeans, Eclipse, Android Studio, etc)
Post Reply
SDG
Newbie
Newbie
Posts: 40
Joined: Tue Apr 08, 2003 4:00 am

Features of Google Finance Charts

Post by SDG » Tue Jan 05, 2010 12:48 pm

Hi All,

Any plans to come-up with features like google finance chart has (Visit - http://www.google.com/finance?q=INDEXDJ ... SDAQ:.IXIC)?

Best,
Veeranna Ronad.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Re: Features of Google Finance Charts

Post by Narcís » Tue Jan 05, 2010 2:45 pm

Hi Veeranna,

This is already possible using existing TeeChart features as explained in those threads:

http://www.teechart.net/support/viewtop ... 80&p=41366
http://www.teechart.net/support/viewtop ... 840#p29840

Those are not TeeChart for Java threads but the same applies to the Java version. Moreover, the interpolating example is also available in TeeChart.Features.jar demo, at Chart Styles -> Standard -> Line (Strip) -> Interpolating lines.

Hope this helps!
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

SDG
Newbie
Newbie
Posts: 40
Joined: Tue Apr 08, 2003 4:00 am

Re: Features of Google Finance Charts

Post by SDG » Wed Jan 06, 2010 6:30 am

Hi Narcis,

Thanks for the solution. But I could not convert the sample into Java.
-------------
colorband1.StartLine.DragLine += new EventHandler(ColorBand_DragLine);
colorband1.EndLine.DragLine += new EventHandler(ColorBand_DragLine);

and
void ColorBand_DragLine(object sender, EventArgs e)
{
tChart1.Axes.Bottom.SetMinMax(colorband1.Start, colorband1.End);
}
----------------

Kindly advice me.

Best,
Veeranna Ronad.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Re: Features of Google Finance Charts

Post by Narcís » Thu Jan 07, 2010 9:16 am

Hi Veeranna,

It seems ColorBand's dragging is not working. I have added the defect to the bug list (TJ71014623) to be fixed. I would expect code below to work.

Code: Select all

        tChart1.getAspect().setView3D(false);
        
        Line line1 = new Line(tChart1.getChart());
        line1.fillSampleValues();
        
        ColorBand colorBand1 = new ColorBand(tChart1.getChart());
        colorBand1.setAxis(tChart1.getAxes().getBottom());
        colorBand1.setStart(5);
        colorBand1.setEnd(15);
        colorBand1.getStartLine().setAllowDrag(true);
        colorBand1.getEndLine().setAllowDrag(true);
        
        colorBand1.addMouseMotionListener( new MouseMotionListener() {
            
            public void mouseDragged(MouseEvent e) {
                tChart1.getHeader().setText(Double.toString(((ColorBand)e.getSource()).getStart()));
            }

            public void mouseMoved(MouseEvent e) {
                //throw new UnsupportedOperationException("Not supported yet.");
            }
        });
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply