gridband problems

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Torte
Newbie
Newbie
Posts: 19
Joined: Fri Sep 16, 2005 4:00 am

gridband problems

Post by Torte » Fri Mar 10, 2006 11:53 am

hi there,

i got a problem with the recoloring the gridband when the grid is activ. When user changes color of the gridband at runtime, the grid is overpainted and not seen anymore...how to avoid this?
bg,
Robert

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

Post by Narcís » Fri Mar 10, 2006 1:02 pm

Hi Robert,

I'm unable to reproduce it here using latest TeeChart version available. Should I follow any specific step to reproduce the issue? Which TeeChart version are you using?

Thanks in advance.
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

Torte
Newbie
Newbie
Posts: 19
Joined: Fri Sep 16, 2005 4:00 am

Post by Torte » Fri Mar 10, 2006 1:28 pm

hi narcis,

im just activating the gridband with

Code: Select all

this.chart.GetGridBand.Active=true;
then asigning colors like

Code: Select all

this.chart.GetGridBand.Band1.Color=this.colorDialog5.Color;
this.chart.GetGridBand.Band2.Color=this.colorDialog6.Color;
and then the grid is gone.
I am using Teechart .NET V2.
regards,
Robert

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

Post by Narcís » Fri Mar 10, 2006 2:19 pm

Hi Robert,

It works fine here using the code below and latest TeeChart for .NET v2 debug build available at our Customer Download Area. Can you please test if this works at your end and, if necessary, modify the code so that we can reproduce the problem here?

Code: Select all

    private void Form1_Load(object sender, EventArgs e)
    {
      line1.FillSampleValues();

      this.colorDialog1.Color = Color.Gray;
      this.colorDialog2.Color = Color.Red;      

      this.gridBand1.Band1.Color = this.colorDialog1.Color;
      this.gridBand1.Band2.Color = this.colorDialog2.Color;
    }

    private void button1_Click(object sender, EventArgs e)
    {
      this.colorDialog1.ShowDialog();
      this.gridBand1.Band1.Color = this.colorDialog1.Color;
    }

    private void button2_Click(object sender, EventArgs e)
    {
      this.colorDialog2.ShowDialog();
      this.gridBand1.Band2.Color = this.colorDialog2.Color;
    }
Thanks in advance.
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

Torte
Newbie
Newbie
Posts: 19
Joined: Fri Sep 16, 2005 4:00 am

Post by Torte » Thu Mar 16, 2006 1:11 pm

hi narcis,

looks like it was a matter of tranparency. Since the gridband is painted above the grid its not visible when gridband.bands transparency is set to zero.
The unlogic in this is just that it starts !=0 and when the user sets a bandcolor the transparency is set to 0 which ends in hiding the grid.)

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

Post by Narcís » Fri Mar 17, 2006 10:29 am

Hi Robert,

Yes, you may be right. I ignore why the GridBand tool is initialized with both bands being black. I'll add this to our wish-list to be considered 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