Gradients with stop values

Last post 06-07-2011, 1:16 AM by mshakeel.faiz. 4 replies.
Sort Posts: Previous Next
  •  06-06-2011, 11:34 AM 308607

    Gradients with stop values .NET

    Attachment: Present (inaccessible)

    Hello all,

    I'm using Aspose Cells .NET 4.4 to create charts using gradients:

    e.g.
    chart.NSeries[2].Points[i].Area.FillFormat.SetTwoColorGradient(color1, color2, GradientStyleType.Vertical, 4);

    How is it possible to change the gradient's second stop value from 50% (default) to e.g. 80% (as it is possible in Excel)?

    Thanks in advance for a quick feedback.

    Martin

     
  •  06-06-2011, 3:03 PM 308676 in reply to 308607

    Re: Gradients with stop values .NET

    Attachment: Present (inaccessible)
    Hi Martin,

    Thank you for your sample file.
    Attached to my reply is a snapshot of Excel 2010. Please confirm that you are talking about this feature of MS Excel. If yes then I am afraid, there is no functionality available in Aspose.Cells for .NET API to set the Gradient Fill Stop value other than 50%.
    If you confirm this requirement, then we can log it as "Required Feature" in our system and support it in our future release.

    Babar Raza
    Support Developer,
    Aspose Sialkot Team
    http://www.aspose.com/
    Aspose - Your File Format Experts
     
  •  06-06-2011, 4:25 PM 308693 in reply to 308676

    Re: Gradients with stop values

    Attachment: Present (inaccessible)
    Hi,

    I think you may use our latest version e.g v5.3.2, 5.3.3 to specify gradient stops. You cannot implement the advanced gradient options in older version like v4.4 that you are using. Please see the following sample code here.

      Workbook workbook = new Workbook("e:\\test2\\gradient_sample.xls");
                Worksheet csheet = workbook.Worksheets["Chart"];
                Chart chart = csheet.Charts[0];
                SeriesCollection nseries = chart.NSeries;
              
                Series aseries;
                aseries = nseries[2];

                CellsColor cellColor = workbook.CreateCellsColor();
                cellColor.Color = Color.Blue;

                ChartPointCollection datapoints = aseries.Points;
                for (int i = 0; i < datapoints.Count; i++)
                {
                    datapoints[i].Area.FillFormat.GradientFill.GradientStops.Add(80, cellColor, 2);
                }

                workbook.Save("e:\\test2\\outputFile.xls");

    I have also attached our latest fixed version here.


    Thank you.

    Amjad Sahi
    Support Developer,
    Aspose Sialkot Team
    Contact Us
     
  •  06-07-2011, 12:47 AM 308731 in reply to 308693

    Re: Gradients with stop values

    Thanks for your answer.

     

    Is it possible to upgrade my v4.4 license to 5.3.3 and how much does it costs?

     
  •  06-07-2011, 1:16 AM 308739 in reply to 308731

    Re: Gradients with stop values

    Hi,

    If your license expiry date has not passed, then you are eligible to get new update free of cost.

    Please post your question on Aspose.Purchase forum to get more help.


    Many Thanks and Kind Regards,

    Shakeel Faiz
    Support Developer
    Aspose Sialkot Team
    Contact Us
    Aspose - The .NET and Java Component Publisher

    Keep in touch! We're on Twitter and Facebook
     
View as RSS news feed in XML