Date Format (Culture Settings ignored)

4 posts, 0 answers
  1. Matthias Bibo
    Matthias Bibo avatar
    74 posts
    Member since:
    Mar 2010

    Posted 29 Nov 2012 Link to this post


    Hi,

    I am having some problems with the RadGridView with Row Virtualizing in Silverlight.
    The Date Column seems to randomly Format the Date with German or American formatting.
    See the example:




    If I scroll vertically, the format keeps changing. If I scroll horizontally everything is fine.
    I have both Row Virtualizing and Column Virtualizing active.


    I have tried to set the Culture direclty on the GridView, but it did not solve the problem.

    Am I missing something here?

    Best Regards,
    Matthias Bibo
  2. Dimitrina
    Admin
    Dimitrina avatar
    3769 posts

    Posted 29 Nov 2012 Link to this post

    Hi Matthias,

    So far we are not aware of such an issue.

    May I ask you to try setting a Language for the GridView? Do you use our most recent version - Q3 2012?

    Greetings,
    Didie
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. Matthias Bibo
    Matthias Bibo avatar
    74 posts
    Member since:
    Mar 2010

    Posted 29 Nov 2012 Link to this post


    Hi Didie,

    I have tried with the new Telerik Controls (Q3 2012) and the previous version.

    The Grid is Declared as follows:

    <bdlControls:BDLGridView Grid.Row="2" Grid.Column="1" Grid.RowSpan="2" ValidatesOnDataErrors="InEditMode" ItemsSource="{Binding Items, Mode=TwoWay}" SelectedItem="{Binding CurrentItem, Mode=TwoWay}" CanUserFreezeColumns="False" AutoGenerateColumns="False" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" EnableRowVirtualization="True" EnableColumnVirtualization="True" ShowGroupPanel="False" SelectionMode="Single" CanUserDeleteRows="False" CanUserInsertRows="False" Language="de-DE">
               <bdlControls:BDLGridView.Columns>
                   <bdlControls:BDLGridViewImageColumn Header="" DataMemberBinding="{Binding IconPath}" IsReadOnly="True" Width="Auto" />
                   <bdlControls:BDLGridViewDataColumn Header="Id" DataMemberBinding="{Binding Id}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding Id}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Name" DataMemberBinding="{Binding Name, Mode=TwoWay}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding Name}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Beschreibung" DataMemberBinding="{Binding Description}" MinWidth="40"  Width="*">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding Description}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Angelegt am" DataMemberBinding="{Binding InsertDate}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding InsertDate}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Angelegt von" DataMemberBinding="{Binding InsertUser}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding InsertUser}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Geändert am" DataMemberBinding="{Binding UpdateDate}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding UpdateDate}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
                   <bdlControls:BDLGridViewDataColumn Header="Geändert von" DataMemberBinding="{Binding UpdateUser}" IsReadOnly="True" Width="Auto">
                       <bdlControls:BDLGridViewDataColumn.CellTemplate>
                           <DataTemplate>
                               <TextBlock Text="{Binding UpdateUser}" Foreground="{Binding Converter={StaticResource TemplateConverter}}" />
                           </DataTemplate>
                       </bdlControls:BDLGridViewDataColumn.CellTemplate>
                   </bdlControls:BDLGridViewDataColumn>
               </bdlControls:BDLGridView.Columns>
           </bdlControls:BDLGridView>

    I have tried setting the Language in Xaml (as in code example) and also in Code behind. I also tried setting the CurrenThread Culture.
    Nothing seems to work.

    Best Regards,
    Matthias Bibo
  4. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 03 Dec 2012 Link to this post

    Hello Matthias,

    Actually, we have such an issue logged in our system. You can vote for it here so that it gets with higher priority.  
    Please excuse us for the troubles. 


    All the best,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top