Xamarin.Android

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Interface IOfficeChartBorder

    Show / Hide Table of Contents

    Interface IOfficeChartBorder

    Represents the border of an object.

    Namespace: Syncfusion.OfficeChart
    Assembly: Syncfusion.OfficeChart.Portable.dll
    Syntax
    public interface IOfficeChartBorder

    Properties

    AutoFormat

    Gets or sets a value that indicates the border format as automatic or custom.

    Declaration
    bool AutoFormat { get; set; }
    Property Value
    Type Description
    System.Boolean

    True if border has automatic format.Otherwise False.

    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;
    //Set the auto format
    chartAreaBorder.AutoFormat = false;
    //Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange; 
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Set the auto format
    chartAreaBorder.AutoFormat = False
    'Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    BeginArrowSize

    Get or set the begin arrow length.

    Declaration
    OfficeArrowSize BeginArrowSize { get; set; }
    Property Value
    Type Description
    OfficeArrowSize

    BeginArrowType

    Get or set the begin arrow style.

    Declaration
    OfficeArrowType BeginArrowType { get; set; }
    Property Value
    Type Description
    OfficeArrowType

    ColorIndex

    Gets or sets the color of the border.

    Declaration
    OfficeKnownColors ColorIndex { get; set; }
    Property Value
    Type Description
    OfficeKnownColors
    Remarks

    The color is specified as an index value into the current color palette.

    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;   
    //Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange; 
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange  
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    EndArrowSize

    Get or set end arrow length.

    Declaration
    OfficeArrowSize EndArrowSize { get; set; }
    Property Value
    Type Description
    OfficeArrowSize

    EndArrowType

    Get or set the end arrow style.

    Declaration
    OfficeArrowType EndArrowType { get; set; }
    Property Value
    Type Description
    OfficeArrowType

    IsAutoLineColor

    Gets or sets whether the line color is automatic.

    Declaration
    bool IsAutoLineColor { get; set; }
    Property Value
    Type Description
    System.Boolean

    True if the line color is auto.Otherwise False

    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;  
    //Enable auto line color
    chartAreaBorder.IsAutoLineColor = false;
    //Set the line color
    //chartAreaBorder.LineColor = Color.Chocolate;
    //Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot;
    //Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide;
    //Set the transparency of border
    chartAreaBorder.Transparency = 0.8;
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Enable auto line color
    chartAreaBorder.IsAutoLineColor = False
    'Set the line color
    'chartAreaBorder.LineColor = Color.Chocolate;
    'Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot
    'Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide
    'Set the transparency of border
    chartAreaBorder.Transparency = 0.8
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    LineColor

    Gets or sets the Color of the line.

    Declaration
    Color LineColor { get; set; }
    Property Value
    Type Description
    Color
    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;  
    //Enable auto line color
    chartAreaBorder.IsAutoLineColor = false;
    //Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue;
    //Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot;
    //Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide;
    //Set the transparency of border
    chartAreaBorder.Transparency = 0.8;
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Enable auto line color
    chartAreaBorder.IsAutoLineColor = False
    'Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue
    'Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot
    'Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide
    'Set the transparency of border
    chartAreaBorder.Transparency = 0.8
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    LinePattern

    Gets or sets the Line pattern for the border.

    Declaration
    OfficeChartLinePattern LinePattern { get; set; }
    Property Value
    Type Description
    OfficeChartLinePattern
    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;  
    //Enable auto line color
    chartAreaBorder.IsAutoLineColor = false;
    //Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue;
    //Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot;
    //Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide;
    //Set the transparency of border
    chartAreaBorder.Transparency = 0.8;
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Enable auto line color
    chartAreaBorder.IsAutoLineColor = False
    'Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue
    'Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot
    'Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide
    'Set the transparency of border
    chartAreaBorder.Transparency = 0.8
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    LineWeight

    Gets or sets the Weight of the line.

    Declaration
    OfficeChartLineWeight LineWeight { get; set; }
    Property Value
    Type Description
    OfficeChartLineWeight
    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;  
    //Enable auto line color
    chartAreaBorder.IsAutoLineColor = false;
    //Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue;
    //Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot;
    //Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide;
    //Set the transparency of border
    chartAreaBorder.Transparency = 0.8;
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Enable auto line color
    chartAreaBorder.IsAutoLineColor = False
    'Set the line color
    chartAreaBorder.LineColor = System.Drawing.Color.CornflowerBlue
    'Set the line pattern
    chartAreaBorder.LinePattern = OfficeChartLinePattern.DashDotDot
    'Set the line weight
    chartAreaBorder.LineWeight = OfficeChartLineWeight.Wide
    'Set the transparency of border
    chartAreaBorder.Transparency = 0.8
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()

    Transparency

    Gets or sets the transparency level of the specified Solid color shaded fill as a floating-point value from 0.0 (Clear) through 1.0(Opaque)

    Declaration
    double Transparency { get; set; }
    Property Value
    Type Description
    System.Double
    Examples
    //Create a presentation instance
    IPresentation presentation = Presentation.Create();
    //Add a blank slide to the presentation
    ISlide slide = presentation.Slides.Add(SlideLayoutType.Blank);
    //Add chart to the slide with position and size
    IPresentationChart chart = slide.Charts.AddChart(100, 10, 500, 300);
    //Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan");
    chart.ChartData.SetValue(1, 3, "Feb");
    chart.ChartData.SetValue(1, 4, "March");
    //Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010");
    chart.ChartData.SetValue(2, 2, "60");
    chart.ChartData.SetValue(2, 3, "70");
    chart.ChartData.SetValue(2, 4, "80");
    //Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011");
    chart.ChartData.SetValue(3, 2, "80");
    chart.ChartData.SetValue(3, 3, "70");
    chart.ChartData.SetValue(3, 4, "60");
    //Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012");
    chart.ChartData.SetValue(4, 2, "60");
    chart.ChartData.SetValue(4, 3, "70");
    chart.ChartData.SetValue(4, 4, "80");
    //Create a new chart series with the name
    IOfficeChartSerie serieJan = chart.Series.Add("Jan");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData[2, 2, 4, 2];
    //Create a new chart series with the name
    IOfficeChartSerie serieFeb = chart.Series.Add("Feb");
    //Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData[2, 3, 4, 3];
    //Create a new chart series with the name
    IOfficeChartSerie serieMarch = chart.Series.Add("March");
    //Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData[2, 4, 4, 4];
    //Get the chart area border
    IOfficeChartBorder chartAreaBorder = chart.ChartArea.Border;   
    //Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange; 
    //Set the transparency of border
    chartAreaBorder.Transparency = 0.8;
    //Save the presentation
    presentation.Save("Output.pptx");
    //Close the presentation
    presentation.Close();
    'Create a presentation instance
    Dim presentation__1 As IPresentation = Presentation.Create()
    'Add a blank slide to the presentation
    Dim slide As ISlide = presentation__1.Slides.Add(SlideLayoutType.Blank)
    'Add chart to the slide with position and size
    Dim chart As IPresentationChart = slide.Charts.AddChart(100, 10, 500, 300)
    'Set chart data - Row1
    chart.ChartData.SetValue(1, 2, "Jan")
    chart.ChartData.SetValue(1, 3, "Feb")
    chart.ChartData.SetValue(1, 4, "March")
    'Set chart data - Row2
    chart.ChartData.SetValue(2, 1, "2010")
    chart.ChartData.SetValue(2, 2, "60")
    chart.ChartData.SetValue(2, 3, "70")
    chart.ChartData.SetValue(2, 4, "80")
    'Set chart data - Row3
    chart.ChartData.SetValue(3, 1, "2011")
    chart.ChartData.SetValue(3, 2, "80")
    chart.ChartData.SetValue(3, 3, "70")
    chart.ChartData.SetValue(3, 4, "60")
    'Set chart data - Row4
    chart.ChartData.SetValue(4, 1, "2012")
    chart.ChartData.SetValue(4, 2, "60")
    chart.ChartData.SetValue(4, 3, "70")
    chart.ChartData.SetValue(4, 4, "80")
    'Create a new chart series with the name
    Dim serieJan As IOfficeChartSerie = chart.Series.Add("Jan")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieJan.Values = chart.ChartData(2, 2, 4, 2)
    'Create a new chart series with the name
    Dim serieFeb As IOfficeChartSerie = chart.Series.Add("Feb")
    'Set the data range of chart serie � start row, start column, end row, end column
    serieFeb.Values = chart.ChartData(2, 3, 4, 3)
    'Create a new chart series with the name
    Dim serieMarch As IOfficeChartSerie = chart.Series.Add("March")
    'Set the data range of chart series � start row, start column, end row, end column
    serieMarch.Values = chart.ChartData(2, 4, 4, 4)
    'Get the chart area border
    Dim chartAreaBorder As IOfficeChartBorder = chart.ChartArea.Border
    'Set the color index of chart area border
    chartAreaBorder.ColorIndex = OfficeKnownColors.Light_orange
    'Set the transparency of border
    chartAreaBorder.Transparency = 0.8
    'Save the presentation
    presentation__1.Save("Output.pptx")
    'Close the presentation
    presentation__1.Close()
    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved