Page 1 of 1

AddBubble + color

Posted: Mon Feb 28, 2011 4:38 pm
by 15052665
Hi everybody

I'm using teechart pro 8 on windows server 2003 (Terminal server edition)

I have a smal problem with color .

I use addbubble to put some point on a schema.
Some time, the color i'm puting is not right
I want to color the buble in red, i'm using 'FF0000' but in teechart my bubble is purple.
With yellow ('FFFF00') it's the same problem, but not with green ('00FF40').

Exemple
Image

What I do wrong ?
Thank for your help

Re: AddBubble + color

Posted: Tue Mar 01, 2011 11:49 am
by 10050769
Hello Onyx,

Could you send us a simple project because we can reproduce exactly your problem? And also you can tell which version of TeeChart 8 are you using?

Thanks,

Re: AddBubble + color

Posted: Fri Mar 18, 2011 4:05 pm
by 15052665
Hi
Sorry for my late answer

Thank you for your help

I'm using Teechart 8.0.05.09908 on Magic Software (Edev 9.4sp6c)

This is all the step to create my graph

Maybe I have a problem when a use addBubble

--Variable
V_Teechart_ActiveX
V_OleSerie = Iseries
V_OleItems = ITools

--Call
Call Com V_Teechart_ActiveX.Aspect.View3D ('False')
Call Com V_Teechart_ActiveX.Walls.Back.Picture.LoadImage ('File')
Call Com V_Teechart_ActiveX.Tools.Items.Active ('True')
Call Com V_Teechart_ActiveX.Scroll.Enable (0)
Call Com V_Teechart_ActiveX.Zoom.Enable ('False')
Call Com V_Teechart_ActiveX.RemoveAllSeries

V_OleSerie = Call Com V_Teechart_ActiveX.SeriesList.Items (SerieIndex)
Call Com V_OleSerie.asBubble.Transparency(50)
Call Com V_OleSerie.Marks.Visible('True')

Call Com V_OleSerie.asBubble.AddBubble(50,50,5,'Label',Color)
--if color = orange hexa value = 'FF8400' in decimal = 16745472
--if color = yellow hexa value = 'FFFF00' in decimal = 16776960

Call Com V_Teechart_ActiveX.ToolsAdd(18)
Call Com V_Teechart_ActiveX.Tools.Items.asDragPoint.DragStyle(2)
V_OleItems=Call Com V_Teechart_ActiveX.Tools.Items(SerieIndex)
Call Com V_OleItems.asDragPoint.Series(V_OleSerie)
Call Com V_OleSerie.Active('True')

Call Com V_Teechart_ActiveX.Axis.Bottom.SetMinMax(0,100)
Call Com V_Teechart_ActiveX.Axis.Bottom.Increment(1)
Call Com V_Teechart_ActiveX.Axis.Left.SetMinMax(0,100)
Call Com V_Teechart_ActiveX.Axis.Hide

V_OleSerie=Call Com V_Teechart_ActiveX.Series(SerieIndex)

Call Com V_Teechart_ActiveX.Repaint


Thank again
Bye

Re: AddBubble + color

Posted: Mon Mar 21, 2011 11:20 am
by 10050769
Hello Onyx,

Next code works fine for us, using last version 8 of TeeChartActivex and Visual Basic:

Code: Select all

  TeeCommander1.ChartLink = TChart1.ChartLink
  
  TChart1.Aspect.View3D = False
  TChart1.Scroll.Enable = pmBoth
  TChart1.Zoom.Enable = False
  
  TChart1.AddSeries scBubble
  TChart1.Series(0).asBubble.Transparency = 50
  TChart1.Series(0).Marks.Visible = True
  TChart1.Series(0).asBubble.AddBubble 50, 25, 5, "Label 1", "&hFF0000"
  TChart1.Series(0).asBubble.AddBubble 50, 50, 5, "Label 2", "&hFFFF00"
  TChart1.Series(0).asBubble.AddBubble 50, 75, 5, "Label 3", "&h00FF40"
  
  TChart1.Tools.Add tcDragPoint
  TChart1.Tools.Items(0).asDragPoint.DragStyle = dsY
  
  TChart1.Axis.Bottom.SetMinMax 0, 100
  TChart1.Axis.Bottom.Increment = 1
  TChart1.Axis.Left.SetMinMax 0, 100
Could you check again if you have the correctly syntax of colors according your IDE?

On the other hand, in the customer download page you can find a new maintenance release of TeeChart Activex. I recommend you, update your version, and check again if problem persist.

Thanks,

Re: AddBubble + color

Posted: Mon Mar 21, 2011 2:37 pm
by 15052665
Ok

I will follow your advices.

Thank you

Re: AddBubble + color

Posted: Mon Mar 21, 2011 3:42 pm
by 15052665
I found a solution for my problem of color.

i'm looking for the hexa value for vbred, vbgreen and i fond this board

vbBlack &h00 Black
vbRed &hFF Red
vbGreen &hFF00 Green
vbYellow &hFFFF Yellow
vbBlue &hFF0000 Blue
vbMagenta &hFF00FF Magenta
vbCyan &hFFFF00 Red
vbWhite &hFFFFFF White

If I use this value, the color is good

Thank you for your help

My problem is solved

Re: AddBubble + color

Posted: Mon Mar 21, 2011 3:51 pm
by 10050769
Hello Onyx,

I am glad that you can solve your problem :).

Thanks,