[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

11/03/2009 at 03:17AM PST, ID: 24866669 | Points: 125
[x]
Attachment Details

wpf data grid Binding slow

Asked by DataBasePaneri in Grid, WPF and Silverlight

Tags: wpf data grid Binding slow

Hello

I am binding 10000 record to WPD DataGrid. it takes all most 1 min. why it too slow. any solution or alteration?

Code Behind:

        Dim Da As System.Data.SqlClient.SqlDataAdapter
        Dim ds As New System.Data.DataSet

        Da = New System.Data.SqlClient.SqlDataAdapter("Select DocumentNo From tranInwardHeader", "Data Source=.;Initial Catalog=MyWingoldNext;User ID=sa")
        Da.Fill(ds)

ObjModel.ObjPurchaseList = ds.Tables(0)

Xaml:


            <dg:DataGrid Grid.Row="2"
                        Grid.Column="1"
                        AutoGenerateColumns="False" AlternationCount="2"
                         ItemsSource="{Binding Path=ObjPurchaseList, Mode=OneWay}"
                         >
                <dg:DataGrid.Columns>

                    <!--Item Description -->
                    <dg:DataGridTemplateColumn Header="Document No"  Width="200"
                               HeaderStyle="{DynamicResource LeftAlignedColumnHeaderStyle}" >
                        <dg:DataGridTemplateColumn.CellTemplate>
                            <DataTemplate>
                                <TextBlock
                                        Text="{Binding Path=DocumentNo,
                                                Mode=OneWay}"/>
                            </DataTemplate>
                        </dg:DataGridTemplateColumn.CellTemplate>
                    </dg:DataGridTemplateColumn>
            </Grid>


[+][-]11/03/09 06:57 AM, ID: 25729512

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20090824-EE-VQP-74 - Hierarchy / EE_QW_3_20080625