Collaborate forum
cancel
Showing results for 
Search instead for 
Did you mean: 

Problem when using expressions to calculate the number of occupants automatically

Hi,

I;m struggling with the following: I use follow the directions of this page: https://helpcenter.graphisoft.com/knowledgebase/86867/ to calculate the number of occupants. The problem I face is when I have a parameter of occupancy that is not an integer, like say 2.6 or 3.2 those number get rounded up resulting in erroneous results. The expression used is
STRTONUM ( SPLITRIGHT ( {Property:ZONES/Occupancy type}, "| ", 2 ) )

Why is this happening? Does the roundup function in the Occupants affect also the Occupant load value?
Mac OSX 10.14.6 | AC 24 INT 3008 FULL
2 REPLIES 2

runxel
Mentor
Be sure that the "occupants load" number is a real, natural number (float), and not an integer; this is to be set in the property's value type.
Then everything should work fine.

I am not aware what the decimal seperator in Greece is. In Germany it's the comma.
You'll need to have the number in "occupancy type" be in the same format as per your PC's settings.

Lastly I would rather "ROUNDDOWN" than up... since rounding up makes no sense – if there is not enough space left you can't cram more people in, right?!
AC 24 [ger] | Win 10 | Developer of the GDL plugin for Sublime Text |
«Furthermore, I consider that Carth... yearly releases must be destroyed»

Thanks @runxel.

Actually I used "ROUNDUP" because I'm calculating the maximum number of people that can fit in a given space, according to the fire standards
Mac OSX 10.14.6 | AC 24 INT 3008 FULL

Still looking?

Browse more topics

Back to forum

See latest solutions

Accepted solutions

Start a new discussion!