This is a migrated thread and some comments may be shown as answers.

Combining Column and Line graph

5 Answers 261 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
padhu
Top achievements
Rank 1
padhu asked on 14 Apr 2020, 02:55 PM

I followed the article to create a report and having few issues. 

1. The combined report does not show 2 y-axis coordinates. (graph3 and graph2 combined to graph 1)

2. When issue 1 is resolved, can I position the 2nd y-axis coordinates to show up the opposite side (on the left side 1 coordinate and the right side the other coordinate)

3. The x-axis co-ordinate Label format is set to Percent format (0:P0)  but does not display right (like 10%, 20%...)

4. Can I position the legend to the bottom of the graph?

5 Answers, 1 is accepted

Sort by
0
padhu
Top achievements
Rank 1
answered on 16 Apr 2020, 01:21 AM

So I figured out few my questions, but still stuck at few

1. The Y axis for LineSeries : I was able to position the label "AtMaximum" but the Axis Line is still at the Left. Can I move that to the Label (AtMaximum)

2. The Label format at the XAxis still wont show the Percent Format (Like the Y Axis labels)

 

Suggestions appreciated.

 

0
Ivan Hristov
Telerik team
answered on 17 Apr 2020, 09:32 AM

Hi Padhu,

Up to your questions:

1. The position of the axis is controlled by the CrossAxisPositions of the axis it crosses. So in order to move the Y axis to the maximum of the X axis, the X axis scale must define a CrossAxis position which determines where the X axis will be crossed by one or more Y axes. In the attached video you can see how to configure it.

2. From the provided screenshot I cannot determine what the type of the XAxis scale is, but in case it's CategoryScale, then you can use the CategoryGroup's Label property to format the axis label.

Hope this helps.

Regards,
Ivan Hristov
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
padhu
Top achievements
Rank 1
answered on 17 Apr 2020, 01:49 PM

Hi Ivan Hristov,

 

1.Your solution would have been sufficient, if the graph is single series. My graph has a column and a line series. When I implement the suggestion on the shared GraphAxis(X) the Y axis of both the series move to the maximum. When I add distinct GraphAxis for X of both series, I get the desired output for the Y axis, but the X axis duplicates one below the other. Any suggestion on removing the duplicate X axis?  (Attached the trdx file with csvdata)

 

2. I was able to format the Label in CategoryGroup.

 

3. In a single series column graph, is there a way of not showing any legend. When I remove the Legends from the trdx, it still shows the color box without any text.

 

 

0
Accepted
Ivan Hristov
Telerik team
answered on 21 Apr 2020, 07:29 AM

Hello Padhu,

1. The CrossAxisPositions property is a collection, which means it can contain more than one definition on how the axes cross each other. In the current scenario the collection should have two entries: one set at Minimum and one - at Maximum. These entries will be applied to the crossing axes in the order they are added to the CoordinateSystems collection.

2. I'm glad to hear you managed to apply the correct format in the CategoryGroup's Label.

3. The Legend property of the graph has its Style property and you can set its Visibility to false if you do not need to show any Legend at all. Each series has its own Legend Item and if it is needed to specifically set its visibility, you can do that through the series' LegendItem property. Its text and mark have their own style properties (Style and MarkStyle) so you can configure which one to be visible. Please check the following diagram that shows how the styles are applied to the Graph items:  Style Resolving Fallback Algorithm.

Regards,
Ivan Hristov
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
padhu
Top achievements
Rank 1
answered on 28 Apr 2020, 05:08 PM

1 and 3 : Used the Style.visible to hide the additional xaxis(1) and Legend(3)

Thanks for the suggestions!!

Tags
General Discussions
Asked by
padhu
Top achievements
Rank 1
Answers by
padhu
Top achievements
Rank 1
Ivan Hristov
Telerik team
Share this question
or