Hi Aurélien,
In order to use date time values for the x axis you must add valid date times to the x value in the mesh surface series. The following code snippet shows how to do that:
NChart chart = nChartControl1.Charts[0];
chart.Enable3D = true;
chart.Width = 50;
chart.Height = 50;
chart.Depth = 50;
chart.Axis(StandardAxis.PrimaryX).ScaleConfigurator = new NDateTimeScaleConfigurator();
NMeshSurfaceSeries mesh = new NMeshSurfaceSeries();
DateTime[] dates = new DateTime[4];
DateTime now = DateTime.Now;
dates[0] = now;
dates[1] = now + new TimeSpan(10, 0, 0, 0);
dates[2] = now + new TimeSpan(20, 0, 0, 0);
dates[3] = now + new TimeSpan(30, 0, 0, 0);
Random rand = new Random();
mesh.Data.SetGridSize(4, 4);
for (int x = 0; x < 4; x++)
{
for (int z = 0; z < 4; z++)
{
mesh.Data.SetValue(x, z, rand.Next(10), dates[x], z);
}
}
chart.Series.Add(mesh);
nChartControl1.Controller.Tools.Add(new NSelectorTool());
nChartControl1.Controller.Tools.Add(new NTrackballTool());
nChartControl1.Refresh();
Hope this helps - questions or comments - please feel free...
Best Regards,
Nevron Support Team