dwang Posted December 30, 2008 Report Share Posted December 30, 2008 Hi, everyone, I'm new here, I'm trying to draw multiple stock price at real-time. here is the code I'm using when I get realtime price point, if I only have one instrument (single series), the line is very smooth. If I have more than one, I only see separate point (the lines are broken), I guess different series data point are different (in time?), but I thought that each series should be indenpendent. Is there anything I'm doing wrong? thanks a lot. private void AddPoint(DateTime datetime, double value, int seriesIdx) {chart1.RealTime.BeginAddData(1, RealTimeAction.Append); chart1.Data.X[seriesIdx, 0] = datetime.ToOADate(); chart1.Data.Y[seriesIdx, 0] = value;chart1.RealTime.EndAddData(true, true); chart1.AxisX.LabelsFormat.Format = AxisFormat.Time;chart1.AxisX.LabelsFormat.CustomFormat = "HH:mm:ss";} Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.