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

How to change the ScaleLabel numerical value into string representation in LinearGauge?

In LinearGauge, there is no direct option to format the ScaleLabel input into string representation and this requirement can be achieved by using its CustomRenderer support, which helps to customize each element of LinearGauge control.


For Example,


Consider ScaleLabel numerical value “1” need to be formatted into string representation like “One”.


Following steps will guide in this process.


  1. Define new Custom Renderer class inherited from ILinearGaugeRenderer Interface.
  2. Implement all necessary functions for Custom Rendering purpose in LinearGauge.
  3. Perform the required Number to string formatting in DrawLines function.
  4. Apply Custom Renderer class to LinearGauge.


The following code demonstrates the same.


Code Example: [C#]



Code Example: [VB]





Without Formatting


With Formatting




C#:  LinearGaugeSample


VB:  LinearGaugeSample






Article ID: Published Date: Last Revised Date: Platform: Control: .NET Framework:
9244 09/04/2018 09/04/2018 WinForms LinearGauge 4
Did you find this information helpful?
Add Comment
You must log in to leave a comment

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