We have updated Flexmonster Software License Agreement, effective as of September 30, 2024. Learn more about what’s changed.

problem division zero

Answered
long yu asked on April 12, 2022

hello,
I use data server api as data server.
I  have a problem infinity when diviser by 0.
could you help me ?
thanks a lot

4 answers

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster April 13, 2022

Hello, 
 
Thank you for reaching out to us.
 
Flexmonster provides an option of defining how to show divided by zero values in the grid. The default value is "Infinity".  If you want to use another value, you should define the format, for example, like this:

formats: [{
"name": "",
"divideByZeroValue": "divByZero"
}],

Please check the following example for reference: https://jsfiddle.net/flexmonster/w21Lxskj/
 
Please let us know if it works for you. Feel free to contact us if other questions arise.
 
Kind regards,
Nadia

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster April 20, 2022

Hello,
 
Hope you are doing well.
 
We were wondering if you had a chance to test a suggested approach with the divideByZeroValue property. 
Could you please let us know if our response helped?
 
Looking forward to hearing your feedback.
 
Kind regards,
Nadia

Public
long yu April 20, 2022

yes, i had tried divideByZeroValue, it works well
 
Thanks a lot

Public
Nadia Khodakivska Nadia Khodakivska Flexmonster April 20, 2022

Hi,
 
Thank you for the response.
 
Our team is glad to hear that it works for you.
 
Feel free to contact us if other questions arise.
 
Kind regards,
Nadia

Please login or Register to Submit Answer