Creating BarCharts and Pie Charts in PPTX file for data from SQL Server table

Hi Adnan,


Thanks for your reply but with this provided code I tried but still not getting expected output.



chart.Axes.VerticalAxis.IsNumberFormatLinkedToSource = false;
chart.Axes.VerticalAxis.NumberFormat = “[$-409]h:mm AM/PM;@”;

for (int i = 0; i < dt.Rows.Count; i++)

{

double actualCompletedTime = 0;


if (!string.IsNullOrEmpty(dt.Rows[i][“ActualCompletedTime”].ToString().Trim()))

{

string[] splitTime = dt.Rows[i][“ActualCompletedTime”].ToString().Trim().Split(’:’);


TimeSpan time = new TimeSpan(Convert.ToInt32(splitTime[0]), Convert.ToInt32(splitTime[1]), Convert.ToInt32(splitTime[2]));

actualCompletedTime = Convert.ToDouble(time.TotalDays); //save time as double value to be able to apply number format below

}

series.DataPoints.AddDataPointForBarSeries(fact.GetCell(defaultWorksheetIndex, i + 1, 1, actualCompletedTime));

}

chart.Axes.VerticalAxis.IsAutomaticMaxValue = false;
chart.Axes.VerticalAxis.MaxValue = 24;



I am attaching my current output(current_output.JPG) and expected Output(expected_output.JPG) screensshots.

As shown in expected_output.JPG, I am able to manage somehow but in Y axis only 0,6,12,218,24 coming but not able to show there 00:00, 06:00, 12:00, 18:00, 24:00 format in Y axis. If this format can come in Y axis, my job will be done but not happening. With your given code, I am getting something like current_output.JPG which is not proper.

Attaching my sample project with below files :
a) Default.aspx
b) Default.aspx.cs
c) App_Data folder that contains the database files(mdf, ldf). (Earlier I was using this mdf, ldf file as database but now changed to oracle database. But these mdf, ldf files are also my current table structure.)
d) DATA folder : in which the output PPTX template is present.
e) web.config file.

Regards,
Deb
+91-9740283783

Hi Deb,


Your feedback has been shared with our product team. I request for your patience until further feedback is shared by product team.

We are sorry for your inconvenience,

The issues you have found earlier (filed as SLIDESNET-38130) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.