We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

DataMarker inside a circular gauge- displaying an integer as a percentage value

Thread ID:

Created:

Updated:

Platform:

Replies:

128574 Jan 30,2017 11:23 AM UTC Jan 31,2017 06:55 AM UTC Xamarin.Forms 1
loading
Tags: SfCircularGauge
bg
Asked On January 30, 2017 11:23 AM UTC

I need to display an integer field in the ViewModel as a percentage value inside the gauge, ie if score is 80 for an object, it should be displayed as "80%" inside the gauge. Right now I can bind this property to the gauge header's 'Text', however unlike in PieCharts, DataMarker with 'LabelPostFix' option is unavailable for Circular gauges , so all I am getting inside the gauge is '80'. Is there a way to achieve this  without using custom renderer ? (Please provide an example if Custom Renderer needs to be used.)

Subburaj Pandian Veluchamy [Syncfusion]
Replied On January 31, 2017 06:55 AM UTC

Hi Bg, 
 
Thank you for your interest in Syncfusion products. 
 
Based on the provided information, we have checked and your requirement of setting symbol (%) along with the HeaderText in CircularGauge Xamarin Forms can be achieved by adding the required symbol with the HeaderText in the code behind. Since HeaderText is a String you can convert and set Text as per this requirement. Please refer the below code example, 
 
[c#] 
header.Text = header.Text + "%"; 
 
 
We have prepared sample based on the mentioned scenario, please find the below sample. 
 
Sample link: GaugeHeader_Sample 
 
In the sample, we have added CircularGauge properties in the XAML and bind the pointer values and HeaderText. As mentioned in the code example added the HeaderText in the propertyChanged on HeaderText. 
 
If the given solution doesn’t meet your requirement, could you please revert to us by modifying the provided sample based on your requirement with more information about your query, it will be helpful for us to analyze on it and provide you a better solution. 
 
Regards,  
Subburaj Pandian V.  
 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;