[SOLVED] Showing item value 0.xx in xx%?

Hi,

I can’t find information to display an item value in percent when its value on KNX is 0.xx
Maybe it’s a basic config, but I don’t found any topic or doc about it.
My item config:
Number BureauHumidity “Bureau Humidite [%d %%]” [ “CurrentHumidity” ]

for example when humidity is 44% my item still displayed 0.44 in log then 0% UI.

Regards.

[%.2f %%]

Thanks for the doc and the answer

If you don’t expect values that are bigger than 0.99 and also never have more then 2 values after the point you could do something like this.

Number BureauHumidity "Bureau Humidite [REGEX(s/(\\d).(\\d\\d)/$2/g):%s %%]" {...}
1 Like