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

cells do not display text if DataLoadMode set to Asynchronous

1 Answer 70 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Alex
Top achievements
Rank 1
Alex asked on 26 Sep 2011, 04:31 PM
As per title ... (see attached capture.png ) If set to Synchronous I can see everything.

If I tick a checkbox View All in column filter options the data becomes visible (see capture2.png )

 Below is the code:(telerik version 2011.2.712.1040)

<Grid x:Name="LayoutRoot">
 
        <telerik:RadBusyIndicator IsBusy="{Binding IsBusy, ElementName=GridViewDomainDataSource}">
 
            <Grid >
                <Grid.RowDefinitions>
                    <RowDefinition
                        Height="*" />
                    <RowDefinition
                        Height="Auto" />
                </Grid.RowDefinitions>
                 
                <contextMenu:RadGridViewExt
                            x:Name="GridViewMessages"
                            Background="White"
                            ScrollViewer.HorizontalScrollBarVisibility="Auto"
                            ScrollViewer.VerticalScrollBarVisibility="Auto"
                            HorizontalAlignment="Stretch"
                            VerticalAlignment="Stretch"
                            AutoGenerateColumns="False"
                            IsReadOnly="True"
                            ShowColumnFooters="False"
                            EnableColumnVirtualization="True"
                            EnableRowVirtualization="True"
                            ShowGroupPanel="False"
                            Grid.Row="0"
                            SelectionMode="Extended"
                            SelectionUnit="Cell"
                            ClipboardCopyMode="All"
                            DataLoadMode="Asynchronous"
                            HierarchyChildTemplate="{StaticResource childGridView}"
                            ItemsSource="{Binding Data, ElementName=GridViewDomainDataSource}"
                            RowIsExpandedChanging="GridViewMessages_RowIsExpandedChanging">
                     
                    <telerik:RadContextMenu.ContextMenu>
                        <telerik:RadContextMenu x:Name="MessagesContextMenu">
                            <telerik:RadContextMenu.Items>
                            </telerik:RadContextMenu.Items>
                        </telerik:RadContextMenu>
                    </telerik:RadContextMenu.ContextMenu>
 
                    <telerik:RadGridView.Columns>
                        <telerik:GridViewDataColumn DataMemberBinding="{Binding ID}" Header="ID" Width="Auto" MinWidth="50"/>
                        <telerik:GridViewDataColumn DataMemberBinding="{Binding Message}" Header="Message" Width="Auto" MinWidth="200" MaxWidth="800"/>
                    </telerik:RadGridView.Columns>
                     
                    <telerik:RadGridView.ChildTableDefinitions>
                        <telerik:GridViewTableDefinition/>
                    </telerik:RadGridView.ChildTableDefinitions>
                     
                </contextMenu:RadGridViewExt>
                 
                <telerik:RadDataPager Grid.Row="1" Source="{Binding Data, ElementName=GridViewDomainDataSource}"
                              IsTotalItemCountFixed="False" PageSize="50" Margin="0,0,0,4"
                              Name="RadDataPagerMessages" DisplayMode="All"/>
            </Grid>
 
        </telerik:RadBusyIndicator>
 
        <riaControls:DomainDataSource x:Name="GridViewDomainDataSource"
                                      QueryName="GetMessages"
                                      AutoLoad="False"
                                      LoadSize="100"
                                      PageSize="50"
                                      LoadedData="GridViewDomainDataSource_LoadedData" >
 
            <riaControls:DomainDataSource.DomainContext>
                <context:SomeContextHere/>
            </riaControls:DomainDataSource.DomainContext>
 
        </riaControls:DomainDataSource>
 
    </Grid>

1 Answer, 1 is accepted

Sort by
0
Alex
Top achievements
Rank 1
answered on 26 Sep 2011, 05:56 PM
I found this thread - http://www.telerik.com/community/forums/silverlight/gridview/radgridview-and-asynchronous-load.aspx

It says : "you can safely remove DataLoadMode="Asynchronous" since your service is asynchronous itself. The grid will get chunk of data only if you use paging - DataLoadMode="Asynchronous" is not related to this"

I did that, but I still get a problem (removing DataLoadMode="Asynchronous" fixes empty cells issue - is it a bug?). I get too much data in one request. Basicaly I want to load 100 records and display 50 per page as you can see from my code, but it seem to not work ... any idea? thanks
Tags
GridView
Asked by
Alex
Top achievements
Rank 1
Answers by
Alex
Top achievements
Rank 1
Share this question
or