This is a migrated thread and some comments may be shown as answers.

Kendo grid convert automaticlly strings with decimals to int

1 Answer 428 Views
Grid
This is a migrated thread and some comments may be shown as answers.
IMF
Top achievements
Rank 1
IMF asked on 09 Nov 2017, 09:32 AM

I have this property :

public string Commax_dosismaximam2 = "0,03"

 

And when it renders on the grid it become to 3.

I know is something about the culture because if I change it to "0.03" works fine, but the thing is I made it string to avoid this, I donĀ“t understand why kendo have to convert a string to a int. 

 

Thank you

1 Answer, 1 is accepted

Sort by
0
Konstantin Dikov
Telerik team
answered on 10 Nov 2017, 09:35 AM
Hello,

This could occur if you are setting the type for that field to "number" in the Grid`s dataSource. If that is the case, you need to ensure that the decimal separator corresponds to the culture.


Regards,
Konstantin Dikov
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Tags
Grid
Asked by
IMF
Top achievements
Rank 1
Answers by
Konstantin Dikov
Telerik team
Share this question
or