Author Topic: Display/DM**** Bar Graph with Color Changing Indication  (Read 7341 times)

Offline Lukey

  • PLUS+1 Expert
  • ****
  • Posts: 63
  • Karma: +6/-0
Display/DM**** Bar Graph with Color Changing Indication
« on: March 11, 2023, 04:48:18 PM »
Hello can anyone share code or assist with code for a Bar Graph with Color Changing Bar Indication.

I'd like to change the bar graph and bar color base on a pressure transducer input.

Display is non touch, DM430E.

Thank you.

Offline acmall

  • PLUS+1 Guru
  • *****
  • Posts: 199
  • Karma: +37/-1
Re: Display/DM**** Bar Graph with Color Changing Indication
« Reply #1 on: March 13, 2023, 09:09:08 AM »
The attached is a screen widget I did for a tank level. You may be able to get some ideas or adapt this to you needs.

It has three inputs: -
LvlPct control the level display (0 to 100).
BarColour is the colour of the bar.
BarEnable controls whether the bar is displayed.


Offline Lukey

  • PLUS+1 Expert
  • ****
  • Posts: 63
  • Karma: +6/-0
Re: Display/DM**** Bar Graph with Color Changing Indication
« Reply #2 on: March 21, 2023, 03:09:51 PM »
Thanks acmall, found my issue was how i was addressing the RGB HEX Color code, I failed to put the required 00 on the end thus my graphic wasn't displaying correctly.

For others to reference see my code below, thanks!