Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
375
Cannot Set Time Scale Interval
posted

 

I have a webchart where I want to set the timescale interval for the week.

As depicted in the below picture it can be seen that Fri is repeated.

How can I avoid the repetition and set the scale properly?

 

 

Following is the code I am using to set the X Axis

            AxisItem xAxis = new AxisItem
                                 {
                                     Extent = 10,
                                     axisNumber = AxisNumber.X_Axis,
                                     DataType = AxisDataType.Time,
                                     MajorGridLines =
                                         {
                                             Visible = false
                                         },
                                     SetLabelAxisType = SetLabelAxisType.ContinuousData,
                                     Labels =
                                         {
                                             ItemFormat = AxisItemLabelFormat.Custom,
                                             Orientation = TextOrientation.Horizontal,
                                             Font = new Font("Arial", 8),
                                             FontSizeBestFit = true,
                                             Layout =
                                                 {
                                                     Padding = 3,
                                                     Behavior = AxisLabelLayoutBehaviors.UseCollection
                                                 },
                                            ItemFormatString = "<ITEM_LABEL:ddd>"
                                         },
                                     LineThickness = 1,
                                     TickmarkInterval = 1,
                                     TickmarkStyle = AxisTickStyle.DataInterval,
                                     TickmarkIntervalType = AxisIntervalType.Days
                                 };

 

Thanks in Advance,

Utkarsh

Parents
  • 49378
    posted

    Hi Utkarsh,

    Thank you for posting in the community.

    In this scenario your issue seems to be caused by having multiple entries for the same day which, due to the formatting used causes multiple Friday labels to appear.

     I suggest that you use a Scatter chart for this particular implementaion (the ConnectWithLines property would allow you to show your series as a line). The tickmark interval which you have applied then should then provide you with the desired look and feel. You may find some more useful information regarding this scenario at:

    http://blogs.infragistics.com/forums/p/59469/303034.aspx

    Please feel free to contact me if you have any questions.

     

Reply Children