Hi,
I couldn't able plot values on Y-axis.Wells Fargo recently purchased licence from you.Please provide solution immediatley.We need to solve this problem asap.
Thanks,
arun
Hi,
I couldn't able plot values on Y-axis.Wells Fargo recently purchased licence from you.Please provide solution immediatley.We need to solve this problem asap.
Thanks,
arun
Hi arun,
Do you want to create a chart with custom type: Line Column on 2 Axes? I will add this new chart type to Aspose.Excel. It will be available in the next week.
Can we get by this week end.
I will try my best to make it by this week end. Thanks for you patience.
Please try this attached fix with the following sample code:
Excel excel = new Excel();
Cells cells = excel.Worksheets[0].Cells;
cells["a1"].PutValue(1);
cells["a2"].PutValue(2);
cells["a3"].PutValue(3);
cells["b1"].PutValue(4);
cells["b2"].PutValue(5);
cells["b3"].PutValue(6);
int chartIndex = excel.Worksheets[0].Charts.Add(ChartType.Column, 11, 0, 27, 13);
Chart chart = excel.Worksheets[0].Charts[chartIndex];
chart.NSeries.Add("A1:B3", true);
chart.NSeries[1].Type = ChartType.Line;
chart.SecondValueAxis.IsVisible = true;
excel.Save("C:\\book1.xls");
Thanks Laurence,Y-axis is working fine if I put line,column charts.But if i tried to put two line charts and one column chart,It is giving error.Below is the code which i tried to execute.Source for the chart is given in attached exce file.
Please find the attached excel file, i want to draw charts like in the excel file.
Thanks,
arun
'Generate the second chart sheet
Dim sheetIndex As Integer = excel.Worksheets.Add(SheetType.Chart)
Dim sheet2 As Worksheet = excel.Worksheets(sheetIndex)
sheet2.Name = "Chart"
Dim chartIndex As Integer = sheet2.Charts.Add(ChartType.Line, 5, 5, 20, 15)
Dim chart As Chart = sheet2.Charts(chartIndex)
'Set series
chart.NSeries.Add("Summary!K2:K7", True)
chart.NSeries.Add("Summary!B2:B7", True)
chart.NSeries.Add("Summary!D2:D7", True)
chart.NSeries(0).Type = ChartType.Line
chart.NSeries(1).Type = ChartType.Column
chart.NSeries(2).Type = ChartType.Line
chart.SecondValueAxis.IsVisible = True
'Set category
chart.NSeries.CategoryData = "Summary!A2:A7"
chart.NSeries(0).Name = "Contribution Margin"
chart.NSeries(1).Name = "Number of Relationships"
chart.NSeries(2).Name = "Product Revenue"
chart.MajorGridLines.IsVisible = False
chart.IsLegendShown = True
chart.Legend.Position = LegendPositionType.Bottom
'excel.ChangePalette(Color.FromArgb(255, 255, 200), 53)
chart.PlotArea.Area.ForegroundColor = Color.FromArgb(255, 255, 200)
''Set major grid line color
excel.ChangePalette(Color.FromArgb(121, 117, 200), 54)
chart.MajorGridLines.Color = Color.FromArgb(121, 117, 200)
I am working on this issue and will reply you soon.
Please try this attached fix.
Thanks laurance,It’s working fine now.