Welcome to the Xceed Community | Help
Community Search  

Binding to dataset

Sort Posts: Previous Next
  •  09-02-2008, 5:24 AM Post no. 14741

    Binding to dataset

    I.m using the Xceed datagrid v.2 for WPF, the free one.

    When I bind to the grid using:

    grdExceed.ItemsSource = ds.Tables[TableName].DefaultView

    with a dataset containing around 1000 rows it takes about 3 minutes for it to display.

    Is it supposed to be that slow or what??? 

     

    Filed under: ,
  •  09-02-2008, 9:35 AM Post no. 14759 in reply to 14741

    Re: Binding to dataset

    By default, a grid will take all the room that it requires; therefore, if it is not given a size constraint, such as when it is placed in a StackPanel, and a large amount of data items are present, UI virtualization will be lost—resulting in a significant loss in performance. To preserve UI virtualization when a grid is in a StackPanel, the MaxWidth and MaxHeight properties (or Width and Height) must be used to constrain the grid. As an alternative, a DockPanel or Grid can be used as both impose size constraints on their child elements.
    Technical Writer - Xceed Software

    In three words I can sum up everything I've learned about life: it goes on.
  •  09-03-2008, 3:26 AM Post no. 14821 in reply to 14759

    Re: Binding to dataset

    Awesome!! Thanks Jenny for the quick response. Works like a charm now.

    /Johan Z 

View as RSS news feed in XML
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2008 Xceed Software Inc.