logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
jysaghbini  
#1 Posted : Thursday, March 3, 2016 11:28:37 PM(UTC)
jysaghbini

Rank: Member

Groups: Registered
Joined: 4/17/2015(UTC)
Posts: 17
Lebanon

Thanks: 1 times
Dear Support,

When defining the numerical format as N0, average values are always rounded down. i tried changing it to custom format and set it to 00 or ##, but the values still rounded down.

Is there a way to make it behave differently (round up or down based on value)?

Regards,

Jean-Yves
epf  
#2 Posted : Friday, March 4, 2016 10:31:12 AM(UTC)
epf

Rank: Administration

Groups: Administrators
Joined: 12/20/2013(UTC)
Posts: 676
Switzerland

Thanks: 12 times
Was thanked: 116 time(s) in 113 post(s)
The "00" specifier causes the value to be rounded to the nearest digit preceding the decimal, where rounding away from zero is always used. For example, formatting 34.5 with "00" would result in the value 35.

You can check the MSDN documentation:

I made a try and it works 212.64 is rounded to 213...
jysaghbini  
#3 Posted : Friday, March 4, 2016 11:51:36 AM(UTC)
jysaghbini

Rank: Member

Groups: Registered
Joined: 4/17/2015(UTC)
Posts: 17
Lebanon

Thanks: 1 times
I did try 00 and it still gave me the rounding down.

Just to make sure I understood you correctly, I pick the value I am averaging on, specify custom format and put the value 00 in the Custom Format field, right?

Jean-Yves
epf  
#4 Posted : Friday, March 4, 2016 2:07:35 PM(UTC)
epf

Rank: Administration

Groups: Administrators
Joined: 12/20/2013(UTC)
Posts: 676
Switzerland

Thanks: 12 times
Was thanked: 116 time(s) in 113 post(s)
yes, in my model, I select the element in the Data element, then:
Format: Custom
Custom Format: 00
Perhaps it depends on you computer localization settings...
jysaghbini  
#5 Posted : Friday, March 4, 2016 3:17:04 PM(UTC)
jysaghbini

Rank: Member

Groups: Registered
Joined: 4/17/2015(UTC)
Posts: 17
Lebanon

Thanks: 1 times
It didn't work :(

Is it something that was solved in version 2.0? Because I am using version 1.8.

Thanks
epf  
#6 Posted : Friday, March 4, 2016 3:34:40 PM(UTC)
epf

Rank: Administration

Groups: Administrators
Joined: 12/20/2013(UTC)
Posts: 676
Switzerland

Thanks: 12 times
Was thanked: 116 time(s) in 113 post(s)
No I am sorry, it has nothing to do with the version...
I am surprised that it does not work as it is standard .Net formatting. Check if the issue is not somewhere else.
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.