ColorEachPoint makes me crazy...

TeeChart for ActiveX, COM and ASP
Post Reply
Matheo Soft.
Newbie
Newbie
Posts: 21
Joined: Tue Oct 04, 2011 12:00 am

ColorEachPoint makes me crazy...

Post by Matheo Soft. » Wed Nov 16, 2011 6:11 pm

Dear Support,

Client with Steema for D7, I try now Steema Active to develop web page...

I test actually ActiveX product and I do this sample (see below) but I can't set my Bar Chart with ColorEachPoint to True.

I read your forum, I saw some posts but without solving my problem.

With the code below, I have 3 bars blue, I test also clTeeColor and I have 3 bars black.

could you help me please to solve my problem and obtain a chart with ColorEachPoint.
(and better for me, obtain chart with Opera style color)

Many thanks! !!!

Code: Select all

    
<script language="VBScript">
	SUB FillChart
	    With Chart1
     		'sets up Chart to print from IE's print option
     		.Environment.IEPrintWithPage=True

     		.RemoveAllSeries
     		.AddSeries(1)
     		.Aspect.View3D = False
			.Aspect.gdiplus.active = True
     	 	.Legend.Visible=False
         	.Panel.Gradient.Visible=True
			.Walls.Visible = False


	    End With

		With Chart1.Header
		  .Text.Clear
		  .Transparent = True
		  .Text.Add("MyProject")
		End with

		With Chart1.Footer.Font
			.Name = "Tahoma"
			.Bold = False
        End With

		With Chart1.Series(0)
			 .Clear
			 .asBar.BarStyle = 8
			 .asBar.BarPen.Visible = false
			 .asBar.Transparency = 35

			 .asBar.Shadow.Visible = False
			 .asBar.Emboss.Visible = True
			 .asBar.Emboss.VertSize = 3
			 .asBar.Emboss.HorizSize = -4
			 .asBar.Emboss.color = RGB(192, 192, 192)

			 .Marks.Transparent = True


			 .Add 100, "Apples"  , vbBlue '.Color
		     .Add 300, "Pears"   , vbBlue '.Color
		     .Add 200, "Bananas" , vbBlue '.Color
			 .ColorEachPoint = True


			.Marks.Style = smsValue
		End With

    	Chart1.View3D=False

		Chart1.Legend.Visible=False

		Chart1.Panel.Gradient.Visible=True

    END SUB

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: ColorEachPoint makes me crazy...

Post by Yeray » Fri Nov 18, 2011 3:25 pm

Hi Matheo,

I see you are adding your points with vbBlue color. Note that setting a color for the values, this color set has priority to the ColorEachPoint property.
You could add your values with clTeeColor and the OperaPalette will be used.
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Matheo Soft.
Newbie
Newbie
Posts: 21
Joined: Tue Oct 04, 2011 12:00 am

Re: ColorEachPoint makes me crazy...

Post by Matheo Soft. » Fri Nov 18, 2011 3:34 pm

Hi Yeray,
You could add your values with clTeeColor and the OperaPalette will be used.
ok but if I set to clTeeColor, all my stack are black and the ColorEachPoint don't work also.
May be, clTeeColor is unknow. Do you have the numerical value, may be I can test with it?

And how it knows that it must use OperaPalette. If I want to use another palette how can i do,

Many thx Yeray,
sincelery,
Bruno

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: ColorEachPoint makes me crazy...

Post by Yeray » Mon Nov 21, 2011 3:05 pm

Hi Bruno,
Matheo Soft. wrote:May be, clTeeColor is unknow. Do you have the numerical value, may be I can test with it?
If you want to know the value of a TeeChart constant you can look at the TeeChartDefines.h in your "\Utilities\New VC Classes" folder in your TeeChart ActiveX installation.

Code: Select all

const unsigned long clTeeColor = 536870912;
Matheo Soft. wrote:And how it knows that it must use OperaPalette. If I want to use another palette how can i do,
Please, take a look at the example at "All Features\Welcome!\Aspect\Custom Palettes" to see how to change the palette.
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Matheo Soft.
Newbie
Newbie
Posts: 21
Joined: Tue Oct 04, 2011 12:00 am

Re: ColorEachPoint makes me crazy...

Post by Matheo Soft. » Mon Nov 21, 2011 3:24 pm

Hi Yeray,

Thx a lot ! it works, I don't know why but clTeeColor is unknown ?!!

Do you have already seen this problem ?
I actually use an evaluation version version, is it possible that was that ?

Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: ColorEachPoint makes me crazy...

Post by Yeray » Mon Nov 21, 2011 4:14 pm

Hello Bruno,

I think it was my fault. These constants can be used in VB6 but in VBScript.
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

Matheo Soft.
Newbie
Newbie
Posts: 21
Joined: Tue Oct 04, 2011 12:00 am

Re: ColorEachPoint makes me crazy...

Post by Matheo Soft. » Mon Nov 21, 2011 5:04 pm

Ok, no problem, now I know where I can find them ;)

Post Reply