Spread Windows Forms 7.0 Product Documentation
Clone Method
See Also  Example Support Options
FarPoint.Win.Spread Assembly > FarPoint.Win.Spread Namespace > ExcelSparkline Class : Clone Method


Glossary Item Box

Creates a new object that is a copy of the current instance.

Syntax

Visual Basic (Declaration) 
Public Overrides Function Clone() As Object
Visual Basic (Usage)Copy Code
Dim instance As ExcelSparkline
Dim value As Object
 
value = instance.Clone()
C# 
public override object Clone()

Return Value

A new object that is a copy of this instance.

Example

This example uses the Clone method.
C#Copy Code
FarPoint.Win.Spread.ExcelSparklineSetting eSetting = new FarPoint.Win.Spread.ExcelSparklineSetting();
eSetting.ShowMarkers = true;
eSetting.AxisColor = Color.Cyan;
eSetting.DateAxis = true;
eSetting.DisplayEmptyCellsAs = FarPoint.Win.Spread.Chart.EmptyValueStyle.Gaps;
eSetting.DisplayHidden = true;
eSetting.DisplayXAxis = true;
eSetting.FirstMarkerColor = Color.AliceBlue;
eSetting.Formula = "Sheet1!$A$4:$E$4";
eSetting.HighMarkerColor = Color.Honeydew;
eSetting.LastMarkerColor = Color.Lavender;
eSetting.LineWeight = 2;
eSetting.LowMarkerColor = Color.LawnGreen;
eSetting.ManualMax = 3;
eSetting.ManualMin = 1;
eSetting.MarkersColor = Color.Magenta;
eSetting.MaxAxisType = FarPoint.Win.Spread.SparklineAxisMinMax.Custom;
eSetting.MinAxisType = FarPoint.Win.Spread.SparklineAxisMinMax.Individual;
eSetting.NegativeColor = Color.NavajoWhite;
eSetting.RightToLeft = true;
eSetting.SeriesColor = Color.SeaGreen;
eSetting.ShowFirst = true;
eSetting.ShowHigh = true;
eSetting.ShowLast = true;
eSetting.ShowLow = true;
eSetting.ShowNegative = true;
            
FarPoint.Win.Spread.ExcelSparklineSetting ess = eSetting;
FarPoint.Win.Spread.ExcelSparklineSetting ess1 = (FarPoint.Win.Spread.ExcelSparklineSetting)ess.Clone();
Visual BasicCopy Code
Dim eSetting As New FarPoint.Win.Spread.ExcelSparklineSetting()
eSetting.ShowMarkers = True
eSetting.AxisColor = Color.Cyan
eSetting.DateAxis = True
eSetting.DisplayEmptyCellsAs = FarPoint.Win.Spread.Chart.EmptyValueStyle.Gaps
eSetting.DisplayHidden = True
eSetting.DisplayXAxis = True
eSetting.FirstMarkerColor = Color.AliceBlue
eSetting.Formula = "Sheet1!$A$4:$E$4"
eSetting.HighMarkerColor = Color.Honeydew
eSetting.LastMarkerColor = Color.Lavender
eSetting.LineWeight = 2
eSetting.LowMarkerColor = Color.LawnGreen
eSetting.ManualMax = 3
eSetting.ManualMin = 1
eSetting.MarkersColor = Color.Magenta
eSetting.MaxAxisType = FarPoint.Win.Spread.SparklineAxisMinMax.[Custom]
eSetting.MinAxisType = FarPoint.Win.Spread.SparklineAxisMinMax.Individual
eSetting.NegativeColor = Color.NavajoWhite
eSetting.RightToLeft = True
eSetting.SeriesColor = Color.SeaGreen
eSetting.ShowFirst = True
eSetting.ShowHigh = True
eSetting.ShowLast = True
eSetting.ShowLow = True
eSetting.ShowNegative = True

Dim ess As FarPoint.Win.Spread.ExcelSparklineSetting = eSetting
Dim ess1 As FarPoint.Win.Spread.ExcelSparklineSetting = DirectCast(ess.Clone(), FarPoint.Win.Spread.ExcelSparklineSetting)

Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8

See Also

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.