EcGraph Demo3.   Bar Graph, 3D bars, colors and styles.


The VB code used to generate the above graph...

Public Sub Demo3(EcGraph1 As EcGraph)
  'Bar Graph, 3D bars, colors and styles
  Dim i, X As Double, Y As Double
  With EcGraph1
    Call .Reset 'Always call "Reset" first to clear the page
    
    'Start a new graph on the page..
    Call .NewGraph("Bar Graph, 3D bars, colors and styles")
    Call .BorderStyle(ecCadetDarkBlue, ecLightCyan, 0, 1, , , -1, 7, -1, -1)
    Call .LegendTableStyle(, , 21, 25, , 0, , , , , , True)
    
    'Start a new data set on the graph, and add random points..
    Call .NewDataSet("Data 1")
    Call .SymbolStyle(1, 7, ecLightCyan, 6750208, 1, True) '3D bar, width 5mm
    For i = 1 To 9
      X = 2 * i
      Y = Sqr(i) - Rnd(i) / 2
      Call .AddDataPoint(X, Y)
    Next i
    
    Call .PlotAreaColors(ecBlack, ecDarkBlue, 120, , -6)
    Call .Refresh 'Always end with "Refresh"
  End With
End Sub