Announcement

Collapse
No announcement yet.

Dynamically change widgets properties

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • WKuhl
    replied
    Hi Paul,

    this would mean creating a buckload of widgets to give all possible ranges.
    Drawing this gauge manually now really seems like the lesser evil.

    Thanks for the quick answer and keep up the good work!

    Leave a comment:


  • pauleilio
    replied
    Hello,

    Welcome to the forum.

    The percent properties can only be changed during design time in the object inspector. However, if the range of change is known then it is possible to create multiples of the gauge widget with different percent ranges and then select the required widget based on the percent range that you need to display.

    I hope this helps

    Best regards

    Paul

    Leave a comment:


  • WKuhl
    started a topic Dynamically change widgets properties

    Dynamically change widgets properties

    Hi there,

    i'd like to change the percent-properties of the 3-colored gauge widget during runtime according to user input.
    It seems I can only change those in the Object Inspector before compiling, but not via code.

    A possible workaround seems to be to recreate the gauge widget with graphic primitives (individual lines in a for-loop) as demonstrated in the analogue input demo.
    But before I try that I just wanted to be confirmed that there is in deed no "easier" way around this.

    Thanks a lot for your help!
Working...
X