Jump to content
Software FX Community

3D elements X 2D elements


rafael_reimer
 Share

Recommended Posts

All elements within the chart will be shown with a 3D view with the exception of the Annotation Objects. Below is a sample code that shows how to use the annotation library:

Chart1.Gallery = Gallery_Lines

Chart1.ToolBar = True

'Chart1.View3D = True

' Passing data

Chart1.OpenData COD_Values, 2, 6

Chart1.Value(0, 0) = 10

Chart1.Value(0, 1) = 62

Chart1.Value(0, 2) = 42

Chart1.Value(0, 3) = 16

Chart1.Value(0, 4) = 96

Chart1.Value(0, 5) = 74

Chart1.Value(1, 0) = 45

Chart1.Value(1, 1) = 22

Chart1.Value(1, 2) = 27

Chart1.Value(1, 3) = 38

Chart1.Value(1, 4) = 68

Chart1.Value(1, 5) = 91

Chart1.CloseData COD_Values

'

' Create the annotation objects and add the annotation extension to ChartFX

Dim annot As Cfx62ClientServerAnnotation.AnnotationX

Set annot = New Cfx62ClientServerAnnotation.AnnotationX

Dim arrow As Cfx62ClientServerAnnotation.AnnotationArrow

Set arrow = New Cfx62ClientServerAnnotation.AnnotationArrow

Dim balloon As Cfx62ClientServerAnnotation.AnnotationBalloon

Set balloon = New Cfx62ClientServerAnnotation.AnnotationBalloon

annot.List.Add arrow

annot.List.Add balloon

Chart1.Extensions.Add annot

annot.Enabled = True

' Configure the arrow object

arrow.Color = RGB(250, 128, 114)

arrow.Height = 30

arrow.Width = -30

arrow.Top = 130

arrow.Left = 95

arrow.Border.Color = RGB(255, 0, 0)

' Configure the balloon object

balloon.Text = "My first balloon "

balloon.Attach "Near", 2, "Far", 62

balloon.TailCorner = 2

balloon.ArrowFactor = 10

balloon.Border.Color = RGB(0, 0, 0)

balloon.Color = RGB(255, 215, 0)

balloon.SizeToFit

Make sure that the Annotation .dll is added to your project.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...