Sub Main 'This script shows all the properties of a polar bar chart 'CSW 11/24/3 'Declares GrapherApp as an object Dim GrapherApp As Object 'Creates an instance of the Grapher Application object 'and assigns it to the variable named "GrapherApp" Set GrapherApp = CreateObject("Grapher.Application") 'Makes Grapher visible GrapherApp.Visible = True 'Declares Plot as an object Dim Plot As Object 'Creates a plot document in Grapher and 'assigns it to the variable named "Plot" Set Plot = GrapherApp.Documents.Add(grfPlotDoc) 'Declares Shapes as an object Dim Shapes As Object 'Assigns the AutoShapes collection to 'the variable named "Shapes" Set Shapes = Plot.Shapes 'Declares PolarBarChartGraph as an object Dim PolarBarChartGraph As Object 'Creates a graph and assigns it to the 'variable named "PolarBarChartGraph" Set PolarBarChartGraph = Shapes.AddPolarBarChartGraph(GrapherApp.Path+ _ "\samples\winddata.dat") 'Declare PolarBarChart as an object Dim PolarBarChart As Object 'Set PolarBarChart to the first line plot on 'the PolarBarChartGraph graph Set PolarBarChart = PolarBarChartGraph.Plots.Item(1) '***************************** 'AutoPolarBarChart properties '***************************** 'Returns the angle column Debug.Print "Angle column = "; PolarBarChart.aCol 'Sets the angle column to column D PolarBarChart.aCol = 4 'Returns the radius column Debug.Print "Radius column = "; PolarBarChart.rCol 'Sets the radius column to column C PolarBarChart.rCol = 3 'Return the if the angle width is automatically calculated Debug.Print "Angle width auto or custom = "; PolarBarChart.AutoAngleWidth 'Sets the angle width to custom PolarBarChart.AutoAngleWidth = False 'Returns the angle width Debug.Print "Angle width = "; PolarBarChart.AngleWidth 'Sets the angle width to two degrees PolarBarChart.AngleWidth = 2 'Returns the bar width Debug.Print "Bar width = "; PolarBarChart.barWidth 'Set the bar width to 85 percent PolarBarChart.barWidth = 85 'Returns the fill color Debug.Print "Fill color = "; PolarBarChart.Fill.foreColor 'Sets the fill color to blue PolarBarChart.Fill.foreColor = grfColorBlue 'Returns the label font face Debug.Print "Label font = "; PolarBarChart.Labels.Font.face 'Do not display labels PolarBarChart.Labels.ShowLabels = False 'Return the bar line style Debug.Print "Line style = "; PolarBarChart.line.style 'Set the line color to green PolarBarChart.line.foreColor = grfColorGreen 'Determines if a multivariate polar bar chart is stacked Debug.Print "Stacked (stacked/adjacent) = "; PolarBarChart.Stacked 'Sets the stacking to adjacent PolarBarChart.Stacked = False End Sub