jQWidgets Forums

jQuery UI Widgets Forums Grid getcolumnaggregateddata

This topic contains 1 reply, has 2 voices, and was last updated by  Stanislav 7 years, 2 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • getcolumnaggregateddata #98714

    atomic
    Participant

    Hi guys,

    I have column aggregates (sum) in my jqxGrid. Everything is fine, but when I try to read aggregates value in javascript using
    getcolumnaggregateddata for example
    var tmp = grid.jqxGrid('getcolumnaggregateddata', 'Industry', ['sum']);
    my tmp value is not correct. I should get 100.00 (exact value), but I get 100.00000000000001 instead…
    Am I missing something??
    Thanks.

    getcolumnaggregateddata #98719

    Stanislav
    Participant

    Hello atomic,

    This is javascript related. It will do this unless the number is an exact integer. Sometimes even the same number can show different.
    You can take the number are round it to your desired number.

    I tested a couple of examples, and all returned the same values(with a lot of symbols after the decimal).

    Best Regards,
    Stanislav

    jQWidgets Team
    http://www.jqwidgets.com/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.