Spread Windows Forms 12.0 Product Documentation
SpreadChart Constructor(String,Type,Point,Size,ChartViewType,Boolean)
Example 


FarPoint.Win.Spread Assembly > FarPoint.Win.Spread.Chart Namespace > SpreadChart Class > SpreadChart Constructor : SpreadChart Constructor(String,Type,Point,Size,ChartViewType,Boolean)
The formula.
Type of the series.
The location.
The size.
Type of the view.
if set to true [show legend].
Initializes a new instance of the SpreadChart class.
Syntax
'Declaration
 
Public Function New( _
   ByVal formula As String, _
   ByVal seriesType As Type, _
   ByVal location As Point, _
   ByVal size As Size, _
   ByVal viewType As ChartViewType, _
   ByVal showLegend As Boolean _
)
'Usage
 
Dim formula As String
Dim seriesType As Type
Dim location As Point
Dim size As Size
Dim viewType As ChartViewType
Dim showLegend As Boolean
 
Dim instance As New SpreadChart(formula, seriesType, location, size, viewType, showLegend)
public SpreadChart( 
   string formula,
   Type seriesType,
   Point location,
   Size size,
   ChartViewType viewType,
   bool showLegend
)

Parameters

formula
The formula.
seriesType
Type of the series.
location
The location.
size
The size.
viewType
Type of the view.
showLegend
if set to true [show legend].
Remarks
The formula parameter is for the chart data. The seriesType parameter indicates which type of chart will be added. The location and size parameters specify the location and size (width and height) of the chart. The viewType parameter is the view type of the chart (2D or 3D). The showLegend parameter indicates whether to show a default legend area in the chart.
Example
This example creates a chart.
Point loc = new Point(20,30);
Size size = new Size(300,400);
FarPoint.Win.Spread.Chart.SpreadChart chart = new FarPoint.Win.Spread.Chart.SpreadChart("Sheet1!$A$2:$A$7", typeof(FarPoint.Win.Chart.BarSeries),loc,size,FarPoint.Win.Chart.ChartViewType.View2D,false);
fpSpread1.Sheets[0].Charts.Add(chart);
Dim loc As New Point(20, 30)
Dim size As New Size(300, 400)
Dim chart As New FarPoint.Win.Spread.Chart.SpreadChart("Sheet1!$A$2:$A$7", GetType(FarPoint.Win.Chart.BarSeries), loc, size, FarPoint.Win.Chart.ChartViewType.View2D, False)
fpSpread1.Sheets(0).Charts.Add(chart)
See Also

Reference

SpreadChart Class
SpreadChart Members
Overload List