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

RedGrid sellecting top4 rows on loading with 263105 rows and 24 columns(bind with RadDomainDataSource)

2 Answers 34 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Manoj
Top achievements
Rank 1
Manoj asked on 02 Sep 2011, 12:58 AM
I am using red grid which is bind to domaindata service to load data on demand. It was working fine till I was dealing with less number of rows around 80000. Now my table is having 263105 rows and 24 columns. When I am running application grids top 4 rows appears as selected (see attched pic). It is not expected. I am also trying to unselect by clicking here and there but no luck. Please suggest why this is happening.
XAML code is:
 

<

 

 

brite:BritePage xmlns:brite="clr-namespace:BriteClient.Views"

 

 

 

x:Class="BriteClient.Views.Tracking.AuditTracking"

 

 

 

xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

 

 

 

xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

 

 

 

xmlns:d="http://schemas.microsoft.com/expression/blend/2008"

 

 

 

xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

 

 

 

mc:Ignorable="d"

 

 

 

xmlns:ei="http://schemas.microsoft.com/expression/2010/interactions"

 

 

 

xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"

 

 

 

xmlns:vm="clr-namespace:BriteClient.ViewModels"

 

 

 

xmlns:s="clr-namespace:BriteClient.Web.Services"

 

 

 

xmlns:c="clr-namespace:BriteClient.Controls"

 

 

 

xmlns:con="clr-namespace:BriteClient.Helpers.Converters"

 

 

 

xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation"

 

 

 

xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"

 

 

 

 

Title="AuditAssignment Page"

 

 

 

Style="{StaticResource PageStyle}">

 

 

 

 

<brite:BritePage.Resources>

 

 

 

 

<vm:AuditTrackingViewModel x:Key="AuditTrackingViewMode" d:IsDataSouce="True" />

 

 

 

 

</brite:BritePage.Resources>

 

 

 

 

<brite:BritePage.DataContext>

 

 

 

 

<Binding Source="{StaticResource AuditTrackingViewMode}" />

 

 

 

 

</brite:BritePage.DataContext>

 

 

 

 

<Grid x:Name="LayoutRoot">

 

 

 

 

<ScrollViewer x:Name="PageScrollViewer" Style="{StaticResource PageScrollViewerStyle}">

 

 

 

 

<StackPanel x:Name="ContentStackPanel" Style="{StaticResource ContentStackPanelStyle}">

 

 

 

 

<Border BorderBrush="#FFDADADA" BorderThickness="0,0,1,1" CornerRadius="11" Margin="5">

 

 

 

 

<Border x:Name="borderBlue" BorderBrush="#B2ADBDD1" CornerRadius="10" BorderThickness="1">

 

 

 

 

<Grid>

 

 

 

 

<Grid.Resources>

 

 

 

 

<con:InverseBooleanConverter x:Key="InverseBooleanConverter"/>

 

 

 

 

<!--EditorTemplate for the Name property.-->

 

 

 

 

<DataTemplate x:Key="NameFilterEditorTemplate">

 

 

 

 

<telerik:RadComboBox SelectedValue="{Binding Value, Mode=TwoWay, FallbackValue=null}"

 

 

 

MinWidth="100"/>

 

 

 

 

</DataTemplate>

 

 

 

 

<!--EditorTemplate for the Quantity property.-->

 

 

 

 

<DataTemplate x:Key="SliderFilterEditorTemplate">

 

 

 

 

<telerik:RadSlider Value="{Binding Value, Mode=TwoWay, FallbackValue=0}"

 

 

 

Width="100"

 

 

 

TickPlacement="BottomRight"/>

 

 

 

 

</DataTemplate>

 

 

 

 

<!--EditorTemplate for the Discontinued property.-->

 

 

 

 

<DataTemplate x:Key="DiscontinuedEditorTemplate">

 

 

 

 

<StackPanel Orientation="Horizontal">

 

 

 

 

<telerik:RadToggleButton IsChecked="{Binding Value, Mode=TwoWay, FallbackValue=False}"

 

 

 

Content="Yes"

 

 

 

VerticalAlignment="Center"

 

 

 

Margin="2,1"

 

 

 

/>

 

 

 

 

<telerik:RadToggleButton IsChecked="{Binding Value, Mode=TwoWay, FallbackValue=False, Converter={StaticResource InverseBooleanConverter}}"

 

 

 

Content="No"

 

 

 

VerticalAlignment="Center"

 

 

 

Margin="2,1"

 

 

 

/>

 

 

 

 

</StackPanel>

 

 

 

 

</DataTemplate>

 

 

 

 

<c:CustomRedEditorTemplateSelector x:Key="redEditorTemplateSelector">

 

 

 

 

<c:CustomRedEditorTemplateSelector.EditorTemplateRulesProp>

 

 

 

 

<c:EditorTemplateRule PropertyName="AuditTypeDesc"

 

 

 

DataTemplate="{StaticResource NameFilterEditorTemplate}"/>

 

 

 

 

<c:EditorTemplateRule PropertyName="PolicyExpiredPremium"

 

 

 

DataTemplate="{StaticResource SliderFilterEditorTemplate}"/>

 

 

 

 

<c:EditorTemplateRule PropertyName="Discontinued"

 

 

 

DataTemplate="{StaticResource DiscontinuedEditorTemplate}"/>

 

 

 

 

</c:CustomRedEditorTemplateSelector.EditorTemplateRulesProp>

 

 

 

 

</c:CustomRedEditorTemplateSelector>

 

 

 

 

</Grid.Resources>

 

 

 

 

<Grid.RowDefinitions>

 

 

 

 

<RowDefinition Height="50"></RowDefinition>

 

 

 

 

<RowDefinition Height="Auto"></RowDefinition>

 

 

 

 

<RowDefinition Height="*"></RowDefinition>

 

 

 

 

<RowDefinition Height="Auto"></RowDefinition>

 

 

 

 

</Grid.RowDefinitions>

 

 

 

 

<Grid.ColumnDefinitions>

 

 

 

 

<ColumnDefinition Width="100"></ColumnDefinition>

 

 

 

 

<ColumnDefinition Width="*"></ColumnDefinition>

 

 

 

 

<ColumnDefinition Width="100"></ColumnDefinition>

 

 

 

 

</Grid.ColumnDefinitions>

 

 

 

 

<TextBlock x:Name="HeaderText" Grid.Column="0" Grid.ColumnSpan="3" Style="{StaticResource HeaderTextStyle}"

 

 

 

Text="{Binding Path=Strings.AuditAssignment, Source={StaticResource ApplicationResources}}"/>

 

 

 

 

<!--Expander-->

 

 

 

 

<telerik:RadExpander Grid.Row="1" Grid.ColumnSpan="3" x:Name="radExpander" IsExpanded="True" VerticalContentAlignment="Top"

 

 

 

telerik:AnimationManager.IsAnimationEnabled="True">

 

 

 

 

<telerik:RadExpander.Header>

 

 

 

 

<TextBlock x:Name="expanderCaption" Text="Filter" />

 

 

 

 

</telerik:RadExpander.Header>

 

 

 

 

<telerik:RadExpander.Content>

 

 

 

 

<Grid>

 

 

 

 

<Grid.RowDefinitions>

 

 

 

 

<RowDefinition Height="*"></RowDefinition>

 

 

 

 

</Grid.RowDefinitions>

 

 

 

 

<Grid.ColumnDefinitions>

 

 

 

 

<ColumnDefinition Width="*"></ColumnDefinition>

 

 

 

 

<ColumnDefinition Width="200"></ColumnDefinition>

 

 

 

 

</Grid.ColumnDefinitions>

 

 

 

 

<Border BorderBrush="#FFDADADA" BorderThickness="0,0,1,1" CornerRadius="11" Margin="5">

 

 

 

 

<Border CornerRadius="10" x:Name="brdTest" BorderBrush="#B2ADBDD1" BorderThickness="1,1,1,1">

 

 

 

 

<Grid>

 

 

 

 

<Grid.RowDefinitions>

 

 

 

 

<RowDefinition Height="*"></RowDefinition>

 

 

 

 

</Grid.RowDefinitions>

 

 

 

 

<Grid.ColumnDefinitions>

 

 

 

 

<ColumnDefinition Width="*"></ColumnDefinition>

 

 

 

 

<ColumnDefinition Width="200"></ColumnDefinition>

 

 

 

 

</Grid.ColumnDefinitions>

 

 

 

 

<!--Filter-->

 

 

 

 

<telerik:RadDataFilter Grid.Column="0" HorizontalAlignment="Left" Name="radDataFilter"

 

 

 

MinHeight="150" MaxHeight="150" MinWidth="600" Width="640"

 

 

 

EditorTemplateSelector="{StaticResource redEditorTemplateSelector}"

 

 

 

Margin="1">

 

 

 

 

</telerik:RadDataFilter>

 

 

 

 

<StackPanel x:Name="stkColumnPanel" Grid.Column="1" Background="Transparent" Orientation="Vertical" Margin="2" HorizontalAlignment="Right">

 

 

 

 

<TextBlock Text="Select desired grid columns:" FontWeight="Bold"></TextBlock>

 

 

 

 

<ListBox ItemsSource="{Binding Columns, ElementName=radGridView}" Width="200" MinHeight="150" MaxHeight="150" BorderThickness="0">

 

 

 

 

<ListBox.ItemTemplate>

 

 

 

 

<DataTemplate>

 

 

 

 

<CheckBox Content="{Binding Header}" IsChecked="{Binding IsVisible, Mode=TwoWay}" />

 

 

 

 

</DataTemplate>

 

 

 

 

</ListBox.ItemTemplate>

 

 

 

 

</ListBox>

 

 

 

 

</StackPanel>

 

 

 

 

</Grid>

 

 

 

 

<!--</StackPanel>-->

 

 

 

 

</Border>

 

 

 

 

</Border>

 

 

 

 

<!--Save Panel-->

 

 

 

 

<StackPanel x:Name="stkSaveLoadPanel" Grid.Column="1" Background="Transparent" Orientation="Horizontal">

 

 

 

 

<StackPanel x:Name="stkSavedFilterPanel" Background="Transparent" Orientation="Vertical" Margin="2">

 

 

 

 

<TextBlock Text="Saved filters:" FontWeight="Bold"></TextBlock>

 

 

 

 

<ListBox ItemsSource="{Binding Columns, ElementName=radGridView}" Width="100" MinHeight="150" MaxHeight="150" Margin="5">

 

 

 

 

<ListBox.ItemTemplate>

 

 

 

 

<DataTemplate>

 

 

 

 

<TextBlock Text="Saved Filter 1"></TextBlock>

 

 

 

 

</DataTemplate>

 

 

 

 

</ListBox.ItemTemplate>

 

 

 

 

</ListBox>

 

 

 

 

</StackPanel>

 

 

 

 

<StackPanel x:Name="stkButtonsPanel" Background="Transparent" Orientation="Vertical" Margin="5">

 

 

 

 

<Button x:Name="btnLoadFilter" Width="70" Height="30" Content="Apply Filter" Command="{Binding Path=ApplyFilterCommand}" Margin="5"></Button>

 

 

 

 

<Button x:Name="btnSaveFilter" Width="70" Height="30" Content="Save Filter" Command="{Binding Path=SaveCommand}" Margin="5"></Button>

 

 

 

 

</StackPanel>

 

 

 

 

</StackPanel>

 

 

 

 

</Grid>

 

 

 

 

</telerik:RadExpander.Content>

 

 

 

 

</telerik:RadExpander>

 

 

 

 

<Border Grid.Row="2" Grid.ColumnSpan="3" CornerRadius="10" x:Name="brdGrid" BorderBrush="#B2ADBDD1" BorderThickness="1,1,1,1">

 

 

 

 

<StackPanel x:Name="stkGridPanel" Background="Transparent" Orientation="Vertical" Margin="5">

 

 

 

 

<telerik:RadDomainDataSource x:Name="domainDataSource1" AutoLoad="True"

 

 

 

QueryName="GetVW_AuditAssignments"

 

 

 

PageSize="50">

 

 

 

 

<telerik:RadDomainDataSource.DomainContext>

 

 

 

 

<s:BriteDomainContext />

 

 

 

 

</telerik:RadDomainDataSource.DomainContext>

 

 

 

 

</telerik:RadDomainDataSource>

 

 

 

 

<!--IsBusy="{Binding IsBusy, ElementName=domainDataSource1}"-->

 

 

 

 

<!--Red Grid-->

 

 

 

 

<telerik:RadGridView MinHeight="370" MaxHeight="370" MaxWidth="1150" x:Name="radGridView" AutoGenerateColumns="False" ItemsSource="{Binding DataView, ElementName=domainDataSource1}"

 

 

 

CanUserFreezeColumns="True" SelectionMode="Extended" IsReadOnly="True">

 

 

 

 

<telerik:RadGridView.Columns>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding PolicyNumber}" Header="Policy Number" IsGroupable="True"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding ExpirationDate_CancellationDate}" Header="Expiration/Cancellation Date" DataFormatString="{}{0:d}" UniqueName="AssignmentStartDate" IsGroupable="False" />

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding IsFlatCancelled}" Header="Is Flat Cancelled" IsGroupable="False" />

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding NewBusiness}" Header="New Business" IsGroupable="False" />

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding CustomerName}" Header="Customer Name" IsGroupable="False" IsFilterable="False" IsVisible="False" />

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AuditStatusDesc}" Header="Audit Status Desc" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AuditTypeDesc}" Header="Audit Type Desc" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AuditSubTypeDesc}" Header="Audit Sub Type Desc" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding SentToVA}" Header="Sent To VA" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AuditAssgnPolRecvDate}" Header="Audit Assgn PolRecv Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AssignmentStartDate}" Header="Assignment Start Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding VendorTargetDate}" Header="Vendor Target Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AssignedToReviewerDate}" Header="Assigned To Reviewer Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding ReviewerTargetDate}" Header="Reviewer Target Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding UserID}" Header="UserID" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding AuditVendorName}" Header="Audit Vendor Name" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding ReturnedToVendorDate}" Header="Returned To Vendor Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding Statecode}" Header="State Code" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding City}" Header="City" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding ZipCode}" Header="Zip Code" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding PolicyholderTenure}" Header="Policy Holder Tenure" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding PolicyExpiredPremium}" Header="Policy Expired Premium" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding ReviewerCompletionDate}" Header="Reviewer Completion Date" DataFormatString="{}{0:d}" IsGroupable="False"/>

 

 

 

 

<telerik:GridViewDataColumn DataMemberBinding="{Binding FEIN}" Header="FEIN" IsGroupable="True"/>

 

 

 

 

</telerik:RadGridView.Columns>

 

 

 

 

</telerik:RadGridView>

 

 

 

 

<telerik:RadDataPager

 

 

 

x:Name="radDataPager1"

 

 

 

PageSize="30"

 

 

 

Source="{Binding Items, ElementName=radGridView}"

 

 

 

DisplayMode="All"

 

 

 

AutoEllipsisMode="Both"

 

 

 

NumericButtonCount="10"

 

 

 

IsTotalItemCountFixed="True"/>

 

 

 

 

<Grid>

 

 

 

 

<Grid.RowDefinitions>

 

 

 

 

<RowDefinition Height="*"></RowDefinition>

 

 

 

 

</Grid.RowDefinitions>

 

 

 

 

<Grid.ColumnDefinitions>

 

 

 

 

<ColumnDefinition Width="650"></ColumnDefinition>

 

 

 

 

<ColumnDefinition Width="*"></ColumnDefinition>

 

 

 

 

</Grid.ColumnDefinitions>

 

 

 

 

<Border BorderBrush="#FFDADADA" BorderThickness="0,0,1,1" CornerRadius="11" Margin="5" VerticalAlignment="Center">

 

 

 

 

<Border BorderBrush="#B2ADBDD1" CornerRadius="10" BorderThickness="1">

 

 

 

 

<StackPanel x:Name="stkApplyEditToSelectedPanel" Background="Transparent" Orientation="Horizontal">

 

 

 

 

<StackPanel x:Name="stkAuditTypePanel" Background="Transparent" Orientation="Horizontal" Margin="1">

 

 

 

 

<TextBox x:Name="txtAuditType" IsEnabled="True" Text="Audit Type" BorderThickness="0" VerticalAlignment="Center"/>

 

 

 

 

<ComboBox x:Name="cbAuditType" Width="100" Height="20" VerticalAlignment="Center" />

 

 

 

 

</StackPanel>

 

 

 

 

<StackPanel x:Name="stkAuditPeriodPanel" Background="Transparent" Orientation="Horizontal" Margin="1">

 

 

 

 

<TextBox x:Name="txtAuditPeriod" IsEnabled="True" Text="Audit Period" BorderThickness="0" VerticalAlignment="Center" />

 

 

 

 

<ComboBox x:Name="cbAuditPeriod" Width="100" Height="20" VerticalAlignment="Center" />

 

 

 

 

</StackPanel>

 

 

 

 

<StackPanel x:Name="stkAuditorPanel" Background="Transparent" Orientation="Horizontal" Margin="1">

 

 

 

 

<TextBox x:Name="txtAuditor" IsEnabled="True" Text="Auditor" BorderThickness="0" VerticalAlignment="Center" />

 

 

 

 

<ComboBox x:Name="cbAuditor" Width="100" Height="20" VerticalAlignment="Center" Margin="0,0,25,0" />

 

 

 

 

</StackPanel>

 

 

 

 

<StackPanel x:Name="stkApplyToSelectedPanel" Background="Transparent" Orientation="Horizontal">

 

 

 

 

<Button x:Name="btnToSelected" Width="70" Height="20" Content="Apply" Command="{Binding Path=ApplyFilterCommand}" Margin="1"></Button>

 

 

 

 

</StackPanel>

 

 

 

 

</StackPanel>

 

 

 

 

</Border>

 

 

 

 

</Border>

 

 

 

 

<StackPanel Grid.Column="1" x:Name="stkSuggestionPanel" HorizontalAlignment="Right" Background="Transparent" Orientation="Horizontal">

 

 

 

 

<Button x:Name="btnSuggestion" Width="120" Height="30" Content="Show Suggestion" Command="{Binding Path=SaveCommand}" VerticalAlignment="Center" Margin="0,1,5,1"></Button>

 

 

 

 

<Button x:Name="btnSend" Width="70" Height="30" Content="Send" Command="{Binding Path=SaveCommand}" VerticalAlignment="Center" Margin="0,1,0,1"></Button>

 

 

 

 

</StackPanel>

 

 

 

 

</Grid>

 

 

 

 

</StackPanel>

 

 

 

 

</Border>

 

 

 

 

</Grid>

 

 

 

 

</Border>

 

 

 

 

</Border>

 

 

 

 

</StackPanel>

 

 

 

 

</ScrollViewer>

 

 

 

 

</Grid>

 

</

 

 

brite:BritePage>

 

2 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 05 Sep 2011, 04:14 PM
Hello Manoj,

That is pretty weird. Such selection can happen when the several rows contain one and the same object in .NET terms, i.e. if the class has its Equals method overriden and several different instances can be deemed the same when compared with Equals.

But you said that when the rows were less, it was working correctly, which makes it even weirder. Is it possible that WCF RIA Services gets confused in some way when the amount of data is huge.

Can we do the following. Take your original project and strip down everything that is not needed or you can make a brand new dummy project with RadGridView+RadDomainDataSource+RadDataPager+RadDataFilter. Then bind this dummy project to some kind of dummy DB, if you don't want to share your real one. 

The ideas is that we need to have a fully runnable sample project that exhibits the behavior that you see in your real project so we can attach it to our source code, turn on the debugger and see what is happening. We have tried to reproduce this on our side based on the XAML that you posted, but we could not get this multiple selection behavior. So, it must be something that is specific to your original project, but we don't know what. It 

We will be waiting for a runnable sample project in order to resolve this issue as soon as possible. The most important thing is that it should be runnable when we hit F5 and it should exhibit this weird behavior.

P.S. I just thought of something else. Does this happen if you pull data with the stock DataGrid and the stock DomainDataSource. If it does, we will know where to look for since this is most probably some kind of WCF RIA Services glitch or limitation.

Best wishes,
Ross
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
Manoj
Top achievements
Rank 1
answered on 09 Sep 2011, 08:08 PM
Thanks Ross,
For now I have restricted my project for 90000 rows and it is working fine. When it will grow again I will send you sample.
Tags
GridView
Asked by
Manoj
Top achievements
Rank 1
Answers by
Rossen Hristov
Telerik team
Manoj
Top achievements
Rank 1
Share this question
or