Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
80
Set display format to decimal bound column
posted

Hi!

I'm trying to set the format of  certain columns in my UltraGrid, what I want is that only shows 2 decimal places from the first moment I bind the information. The datatype in the database of this column is decimal (28,8). I've tried to set the MaskInput but this only works when I'm editing the cell, when I end editing, the cell gets the original formating of the database. I've also tried to change de DataType of the column in the DataTable after this is filled, but is not possible because I cannot change DataType of a column once it has data. Also, I've tried to set the Format property of the UltraGridColumn but this property is ignored when the column is bound to a data table .

Is another chance to set the display format of  the decimal column since the moment I bind the data?


Parents
No Data
Reply
  • 469350
    Verified Answer
    Offline posted

    The property you need to set is the Format property. I don't know what you are referring to when you say this property is ignored for bound columns. That is certainly not the case. The Format property will work on any column, bound or unbound. 

Children
No Data