Projection Property Example

The example allows you to see the different effects obtainable by setting the Projection property. To try the example, draw an MSChart and a ComboBox control on a form. Paste the code into the Declarations section, and press F5. Click the ComboBox to see the different settings.

Option Explicit

Private Sub Combo1_Click()
   ' Change the projection when clicked.
   MSChart1.Plot.Projection = Combo1.ListIndex
End Sub

Private Sub Form_Load()
   ' Set the chart to a 3D type. 
   MSChart1.chartType = VtChChartType3dBar
   ' Configure the ComboBox by adding the valid settings.
   With Combo1
      .AddItem "VtProjectionTypePerspective" ' 0
      .AddItem "VtProjectionTypeOblique"      ' 1
      .AddItem "VtProjectionTypeOrthogonal"  ' 2
      .AddItem "VtProjectionTypeFrontal"      ' 3
      .AddItem "VtProjectionTypeOverhead"    ' 4
      .ListIndex = 0
   End With
End Sub