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

RadGrid incorrectly formatting float values to datetime

2 Answers 39 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Mohan Gali
Top achievements
Rank 1
Mohan Gali asked on 04 Nov 2010, 04:56 PM

Hi,

RadGrid has a dynamic float column. Some of its values are getting converted incorrectly to datetime (e.g.: 11.9 to 11/09/2010). May I know if there's a way to prevent this without having to go by column name?

Here's the definition of radgrid in the page:
 

  <telerik:RadGrid ID="grdReportData" runat="server" PageSize="20" AllowSorting="True"

                    AllowPaging="True" AutoGenerateColumns="True" CssClass="grid" ClientSettings-Resizing-AllowColumnResize="true"

                    ClientSettings-Resizing-ResizeGridOnColumnResize="true" ShowFooter="true">

                    <PagerStyle Mode="NextPrevAndNumeric"></PagerStyle>
 
                    <MasterTableView Width="100%" TableLayout="Fixed">
                            <NoRecordsTemplate>
                             No records exist for the given criteria.

                            </NoRecordsTemplate>  

                    </MasterTableView>
                </telerik:RadGrid>

Any help is appreciated.
Regards,
Mohan.

 

 

 

 

 

 

 

 

 

2 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 10 Nov 2010, 09:58 PM
Hello Mohan,

Indeed, this is weird behavior. Unfortunately I'm unable to reproduce it on my end. Can you please provide some more details as to how to recreate your scenario?

Best regards,
Daniel
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Mohan Gali
Top achievements
Rank 1
answered on 10 Nov 2010, 11:46 PM
Thanks for the response. This is resolved.

I later found that columns were formatted to date if the IsDate(CellContent) returns true in grid's itemdatabound. Updated code to fix it.

Regards,
Mohan Murali G.
Tags
Grid
Asked by
Mohan Gali
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Mohan Gali
Top achievements
Rank 1
Share this question
or