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
1100
Data-driven gauge axis
posted

I have the need to build gauges on the fly, based on runtime data.

The axis needs to be data driven - sometimes the gauge shows the range 0-80 sometimes 0-500

is there an easy way to drive a preset gauge design? Or do I have to 'brute force' my way through all the LinearGaugeScale.Axes elements and the LinearGaugeScale.Ranges ?

 

thanks!

 

  • 28496
    Offline posted

    if you have many gauges with a known configuration but some variables, my recommendation is to create a class that wraps the gauge and provides a simplified API.

    basically you write your MiniGauge class which can derive from UltraGauge, set everything up in the constructor, then provide "RangeStart" and "RangeEnd" properties in which the setter does all the indexing into collections and casting and whatnot.

    http://community.infragistics.com/forums/p/7068/30247.aspx#30247