Good afternoon,
I purchased and loaded Reporting today to produce some reports based on our current web application. The first chart I need has an x-axis comprising seconds from the start of a session. The chart shows metrics from an exercise session. I need to change the second values to minutes, but not lose any of the points.
In my web page I have used the following in the markup:
<XAxis>
<LabelsAppearance >
<ClientTemplate>
#= kendo.format(\'{0:N0}\', value / 60)#
</ClientTemplate>
</LabelsAppearance>
<TitleAppearance Text="Minutes" />
My question is how to achieve this in Reporting? I can find the format builder, but this does not seem to allow expressions.
Thank you
6 Answers, 1 is accepted
In the Graph you can use Bindings property of the corresponding Coordinate System to modify run time the exposed Axes properties based on Expressions. I have attached a screenshot for clarity.
If you need more specific advices I suggest to open a Support ticket and elaborate on the exact scenario.
Regards,
Todor
Progress Telerik
Thank you Todor - have just got back to this.
My problem is that every time I put any sort of expression into the bindings all I get back is value 1 repeated. As soon as the binding is removed it goes back to the display of EntryID (which is one entry per second). I have 2 coordinate systems in play - have tried setting one or the other or both and get the same result.
An example is setting the expression for the LabelFormat to something as simple as =Format('X:{0}', Fields.EntryID) - this yields an X:1 for the labels (3 of them along the x axis). Not sure if this is your bug or my bug... I may just be missing something - if you could give an example of formatting these values to make them appear as minutes that would be helpful
The LabelFormat of the Axis can take as an argument only aggregate function. When using Fields.EntryID it falls back to First(Fields.EntryID), hence the observed behavior.
The label of the Category scale can be formatted from the corresponding CategoryGroup -> Label property. Check the attached screenshot for clearance. In this case it is not necessary to use Bindings as the property Value can be directly set with Expressions.
If the problem persists, consider opening a support ticket and attaching a sample report definition for local investigation.
Regards,
Todor
Progress Telerik
If I could figure out how to open a support ticket I would - your suggestion does nothing to my report. I have the entryID numbers showing correctly but need to divide them by 60 (or even 300) to place labels as minutes. Surely this is basic stuff!!!! Even just using your = Format("X:{0}",Fields.EntryID) expression for the label in the category group did not change the labels at all. and if you are providing an example could it least have a formula in there to do what I am attempting.
I paid a lot for this product and will be asking for a refund and looking elsewhere shortly.