Jump to content
Software FX Community

multi series chart example


tomasz
 Share

Recommended Posts

I need to build a multi series chart with XAxis of DateTime? and YAxis of double?

I am using below code which shows XAis in integer instead of DateTime.

What do i need to do tomake this working properly?

Is this corect way do do this?

I guess I need a sample code.

 

private void PlotChart(DataRequest dataRequest)

{

chart1.Gallery = Gallery.Line;

chart1.AxisX.AutoScale =

true;chart1.AxisX.AutoMargin = true;

chart1.AxisX.Min =

new DataUnit(Convert.ToDateTime(txtStartDate.Text));chart1.AxisX.Max = new DataUnit(Convert.ToDateTime(txtEndDate.Text));chart1.AxisX.DataFormat.FormatDateTime(new DateTime(2009,8,12));

chart1.Data.Series = dataRequest.VqtRequestsList.Count;

int j = 0;foreach (VqtRequest vqtRequest in dataRequest.VqtRequestsList)

{

int i = 0;foreach (VqtData vqt in vqtRequest.VqtDataList)

{

chart1.Data.Y[j, i] = vqt.Value;

chart1.Data.X[j, i] = (DateTime)vqt.TimeStamp;

i++;

}

j++;

}

}

 

 

 

 

Link to comment
Share on other sites

 Hi Tomas,

 please send a mail to support[@]softwarefx[.]com in order to send you a sample. Also if you have any other question, please write it on the mail.

** Remove brackets from the mail. I put them in order to avoid so spam bots.

Always glad to help.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...