I have a chart that is connected to a DataTable datasource, it returns 32 rows and the labels on the "X" axis all appear Horzontal instead of vertical, I have attempted the following with no success
ultraChart1.Axis.X.Labels.Orientation = TextOrientation.VerticalLeftFacing;
or
ultraChart1.Axis.X.Labels.Orientation = TextOrientation.Custom;
ultraChart1.Axis.X.Labels.OrientationAngle = 90;
can anyone offer any additional help.
Try this:
ultraChart1.Axis.X.Labels.VerticalAlign = System.Drawing.StringAlignment.Center;ultraChart1.Axis.X.Labels.Orientation = infragistics.UltraChart.Shared.Styles.TextOrientation.Custom;ultraChart1.Axis.X.Labels.OrientationAngle = 270;ultraChart1.Axis.X.Labels.Flip = true;
Here is the complete code I am whinning about... I would like the text on the "X" axis to be verticalleftfacing and I would also like to control the scaling of the "Y" axis to be from 0 - 50 scaled in increments of 10. I hope someone can be of assistance.
UltraChart ultraChart1 = new UltraChart();
ultraChart1.ID = "UltraChart1";
mydata.Columns.Add("OnPeak", typeof(double));
mydata.Rows.Add(new object[ {"Sat 3/1/2008",34,12});
mydata.Rows.Add(new object[ { "Sat 3/3/2008", 26, 9 });
ultraChart1.Width = 650;
ultraChart1.Height = 400;
ultraChart1.Axis.Y.RangeMax = 30;
ultraChart1.Axis.Y.RangeMin = 0;
ultraChart1.Border.CornerRadius = 10;
ultraChart1.Axis.X.Labels.OrientationAngle = 270;
ultraChart1.Axis.X.Labels.Flip = true;
//ultraChart1.ColorModel.ModelStyle = ColorModels.CustomLinear;
ultraChart1.DataSource = mydata;
ultraChart1.Data.DataBind();
ultraChart1.RenderControl(htmlWriter);
return stringWriter.ToString();
thanks, that worked great!!!
in stacked charts, the labels that are visible are Series labels...
ultraChart1.Axis.X.Labels.SeriesLabels.Orientation = TextOrientation.VerticalLeftFacing;