Welcome to Smart Home Forum by FIBARO
Dear Guest,
as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.
As a member you can:
- Start new topics and reply to others
- Follow topics and users to get email updates
- Get your own profile page and make new friends
- Send personal messages
- ... and learn a lot about our system!
Regards,
Smart Home Forum by FIBARO Team
Question
Lambik 192
Hi,
Maybe someone can help me to figure out this one.
I have a table with tis content:
Please login or register to see this code.
What I'm trying to do?
I want to strip the tablecontents so that the b-values represents levels with, in this case, icon-id's, sorted from the highest level to the lowest level.
It should be flexible to add more values in the table without worrying where to put it (i.e. if put b98 = 1067 to the top the ouput should be automatically be organized.
The output from the top table should be:
Values b:
if between 95 and 100 percent then iconnumber 1068
if between 50 and 100 percent then iconnumber 1069
if between 30 and 50 percent then iconnumber 1070
if between 5 and 30 percent then icon number 1071
When the a insetion is made in the tail of the table 'b98 = 1067' then the result should be:
if between 98 and 100 percent then iconnumber 1067
if between 95 and 98 percent then iconnumber 1068
if between 50 and 100 percent then iconnumber 1069
if between 30 and 50 percent then iconnumber 1070
if between 5 and 30 percent then icon number 1071
Is there a smart way to do this?
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.