Show grid on ColorGrid problem

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
inea
Newbie
Newbie
Posts: 11
Joined: Fri May 13, 2005 4:00 am

Show grid on ColorGrid problem

Post by inea » Tue Feb 01, 2011 1:12 pm

Hello,

I have a problem.

Why grid in this example is not shown?

Code: Select all

        public Form1()
        {
            InitializeComponent();
            InitializeChart();
        }

        private void InitializeChart()
        {
            tChart1.Aspect.View3D = false;
            tChart1.Dock = DockStyle.Fill;

            Steema.TeeChart.Styles.ColorGrid colorGrid1 = new Steema.TeeChart.Styles.ColorGrid(tChart1.Chart);
            colorGrid1.IrregularGrid = true;
            PopulateSeries(colorGrid1);

            tChart1.Axes.Bottom.SetMinMax(colorGrid1.MinXValue(), colorGrid1.MaxXValue() + 1);
        }

        private void PopulateSeries(Steema.TeeChart.Styles.ColorGrid colorGrid)
        {
            Steema.TeeChart.Styles.ColorGrid colorGridAux = new Steema.TeeChart.Styles.ColorGrid();

            colorGridAux.Add(649525.00, 1840735.13, 6220.000);
            colorGridAux.Add(649525.00, 1840747.63, 6228.000);
            colorGridAux.Add(649525.00, 1840760.13, 6240.000);
            colorGridAux.Add(649525.00, 1840772.63, 6244.000);
            colorGridAux.Add(649525.00, 1840785.13, 6252.000);
            colorGridAux.Add(649525.00, 1840797.63, 6260.000);
            colorGridAux.Add(649525.00, 1840810.13, 6268.000);
            colorGridAux.Add(649525.00, 1840822.63, 6276.000);
            colorGridAux.Add(649525.00, 1840835.13, 6304.000);
            colorGridAux.Add(649525.00, 1840847.63, 6312.000);
            colorGridAux.Add(649525.00, 1840860.13, 6324.000);
            colorGridAux.Add(649525.00, 1840872.63, 6328.000);
            colorGridAux.Add(649525.00, 1840885.13, 6336.000);
            colorGridAux.Add(649525.00, 1840897.63, 6336.000);
            colorGridAux.Add(649525.00, 1840910.13, 6336.000);
            colorGridAux.Add(649525.00, 1840922.63, 6340.000);
            colorGridAux.Add(649525.00, 1840935.13, 6344.000);
            colorGridAux.Add(649525.00, 1840947.63, 6348.000);
            colorGridAux.Add(649525.00, 1840960.13, 6352.000);
            colorGridAux.Add(649525.00, 1840972.63, 6352.000);
            colorGridAux.Add(649525.00, 1840985.13, 6356.000);
            colorGridAux.Add(649525.00, 1840997.63, 6360.000);
            colorGridAux.Add(649525.00, 1841010.13, 6364.000);
            colorGridAux.Add(649525.00, 1841022.63, 6364.000);
            colorGridAux.Add(649525.00, 1841035.13, 6368.000);
            colorGridAux.Add(649525.00, 1841047.63, 6372.000);
            colorGridAux.Add(649525.00, 1841060.13, 6376.000);
            colorGridAux.Add(649525.00, 1841072.63, 6376.000);
            colorGridAux.Add(649525.00, 1841085.13, 6380.000);
            colorGridAux.Add(649525.00, 1841097.63, 6380.000);
            colorGridAux.Add(649525.00, 1841110.13, 6384.000);
            colorGridAux.Add(649525.00, 1841122.75, 6384.000);
            colorGridAux.Add(649525.00, 1841135.13, 6384.000);
            colorGridAux.Add(649525.00, 1841147.63, 6388.000);
            colorGridAux.Add(649525.00, 1841160.13, 6388.000);
            colorGridAux.Add(649525.00, 1841172.63, 6388.000);
            colorGridAux.Add(649525.00, 1841185.13, 6388.000);
            colorGridAux.Add(649525.00, 1841197.63, 6388.000);
            colorGridAux.Add(649525.00, 1841210.13, 6392.000);
            colorGridAux.Add(649525.00, 1841222.63, 6392.000);
            colorGridAux.Add(649525.00, 1841235.13, 6392.000);
            colorGridAux.Add(649525.00, 1841247.63, 6392.000);
            colorGridAux.Add(649525.00, 1841260.13, 6392.000);
            colorGridAux.Add(649525.00, 1841272.63, 6396.000);
            colorGridAux.Add(649525.00, 1841285.13, 6396.000);
            colorGridAux.Add(649525.00, 1841297.63, 6400.000);

            for (int i = 0; i < colorGridAux.Count; i++)
            {
                colorGrid.Add(colorGridAux.XValues[i], colorGridAux.ZValues[i], colorGridAux.YValues[i]);
            }

            colorGridAux.Dispose();
        }

I think, that always when Xvalues/Yvalues in DataSource is bigger then 1, Grid isn't shown.
Am I right?

Thank you for your answer.

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

Re: Show grid on ColorGrid problem

Post by Narcís » Wed Feb 02, 2011 1:04 pm

Hi inea,

Yes, that's right, this is a bug (TF02015377) which I added to the defect list to be fixed for future releases.
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