Sorting a filtering a generic list bound to a paged GridView?

Discussion in 'ASP .Net' started by Harry Haller, Feb 1, 2007.

  1. Harry Haller

    Harry Haller Guest

    Hello, I want to implement a generic list which will be used to
    display 7 columns in a GridView. One should be able to sort, filter
    and page each of the 7 columns. Ideally the filter should be
    implemented simultaneously for multiple columns - but the data need
    only be sorted by a single column at a time. Sorting should be both
    ascending and descending.

    I'm currently using a DataView but it's far too slow, because there
    are a large number of rows. When full, there are about 2000 rows to
    the DataView and 15 columns. None of the columns are particularly
    long.

    The filtering is done with 7 DropDownLists to which data is bound -
    each of the dropdowns has a value and text display - for instance
    ConsultantID, ConsultantName

    The DataView looks like this:

    TransactionID, ConsultantID, ConsultantName, ManagerID, ManagerName,
    AssetClassCode, AssetClassName, ... etc.

    The IDs are generally integers and the Codes - single or double
    characters, only the Names are displayed in the GridView - the IDs and
    Codes are there to speed up filtering.

    I've seen some examples on the web.

    Should I be following the methods that use delegates for the sorting?

    Is FindAll() with a List<T> suitable for all the filtering?

    Am I better off using a BindingList<T> rather than a List<T>
     
    Harry Haller, Feb 1, 2007
    #1
    1. Advertising

  2. Harry Haller

    RobinS Guest

    Are you talking about GridView or DataGridView? VB or C#? WebForms or
    Windows FOrms? .Net 2.0 or .Net 1.1?

    Robin S.
    ------------------------------
    "Harry Haller" <> wrote in message
    news:...
    > Hello, I want to implement a generic list which will be used to
    > display 7 columns in a GridView. One should be able to sort, filter
    > and page each of the 7 columns. Ideally the filter should be
    > implemented simultaneously for multiple columns - but the data need
    > only be sorted by a single column at a time. Sorting should be both
    > ascending and descending.
    >
    > I'm currently using a DataView but it's far too slow, because there
    > are a large number of rows. When full, there are about 2000 rows to
    > the DataView and 15 columns. None of the columns are particularly
    > long.
    >
    > The filtering is done with 7 DropDownLists to which data is bound -
    > each of the dropdowns has a value and text display - for instance
    > ConsultantID, ConsultantName
    >
    > The DataView looks like this:
    >
    > TransactionID, ConsultantID, ConsultantName, ManagerID, ManagerName,
    > AssetClassCode, AssetClassName, ... etc.
    >
    > The IDs are generally integers and the Codes - single or double
    > characters, only the Names are displayed in the GridView - the IDs and
    > Codes are there to speed up filtering.
    >
    > I've seen some examples on the web.
    >
    > Should I be following the methods that use delegates for the sorting?
    >
    > Is FindAll() with a List<T> suitable for all the filtering?
    >
    > Am I better off using a BindingList<T> rather than a List<T>
     
    RobinS, Feb 1, 2007
    #2
    1. Advertising

  3. Harry Haller

    mark4asp Guest

    On Thu, 1 Feb 2007 00:59:34 -0800, "RobinS" <>
    wrote:

    >Are you talking about GridView or DataGridView? VB or C#? WebForms or
    >Windows FOrms? .Net 2.0 or .Net 1.1?


    GridView with ASP.NET 2.0

    Even when I run my DataView version locally it's taking 15 seconds to
    complete the page, much longer when it's run over the web.

    >Robin S.
    >------------------------------
    >"Harry Haller" <> wrote in message
    >news:...
    >> Hello, I want to implement a generic list which will be used to
    >> display 7 columns in a GridView. One should be able to sort, filter
    >> and page each of the 7 columns. Ideally the filter should be
    >> implemented simultaneously for multiple columns - but the data need
    >> only be sorted by a single column at a time. Sorting should be both
    >> ascending and descending.
    >>
    >> I'm currently using a DataView but it's far too slow, because there
    >> are a large number of rows. When full, there are about 2000 rows to
    >> the DataView and 15 columns. None of the columns are particularly
    >> long.
    >>
    >> The filtering is done with 7 DropDownLists to which data is bound -
    >> each of the dropdowns has a value and text display - for instance
    >> ConsultantID, ConsultantName
    >>
    >> The DataView looks like this:
    >>
    >> TransactionID, ConsultantID, ConsultantName, ManagerID, ManagerName,
    >> AssetClassCode, AssetClassName, ... etc.
    >>
    >> The IDs are generally integers and the Codes - single or double
    >> characters, only the Names are displayed in the GridView - the IDs and
    >> Codes are there to speed up filtering.
    >>
    >> I've seen some examples on the web.
    >>
    >> Should I be following the methods that use delegates for the sorting?
    >>
    >> Is FindAll() with a List<T> suitable for all the filtering?
    >>
    >> Am I better off using a BindingList<T> rather than a List<T>

    >
     
    mark4asp, Feb 1, 2007
    #3
  4. Harry Haller

    RobinS Guest

    I don't do web stuff, I do windows forms. Brian Noyes wrote a Data Binding
    book, and tells how to do sorting and filtering on a DataGridView in
    WinForms on a list of business objects. If you think that would help you,
    check out his book. He also has the sample code online at
    http://softinsight.com/databindingbook. Check out Chapter 9, Customer
    Business Objects.

    He also has some info about web forms in his book, but since I don't do web
    stuff, I didn't read it that closely.

    Hope this helps.

    Robin S.
    Ts'i mahnu uterna ot twan ot geifur hingts uto.
    ---------------------------------------
    "mark4asp" <> wrote in message
    news:...
    > On Thu, 1 Feb 2007 00:59:34 -0800, "RobinS" <>
    > wrote:
    >
    >>Are you talking about GridView or DataGridView? VB or C#? WebForms or
    >>Windows FOrms? .Net 2.0 or .Net 1.1?

    >
    > GridView with ASP.NET 2.0
    >
    > Even when I run my DataView version locally it's taking 15 seconds to
    > complete the page, much longer when it's run over the web.
    >
    >>Robin S.
    >>------------------------------
    >>"Harry Haller" <> wrote in message
    >>news:...
    >>> Hello, I want to implement a generic list which will be used to
    >>> display 7 columns in a GridView. One should be able to sort, filter
    >>> and page each of the 7 columns. Ideally the filter should be
    >>> implemented simultaneously for multiple columns - but the data need
    >>> only be sorted by a single column at a time. Sorting should be both
    >>> ascending and descending.
    >>>
    >>> I'm currently using a DataView but it's far too slow, because there
    >>> are a large number of rows. When full, there are about 2000 rows to
    >>> the DataView and 15 columns. None of the columns are particularly
    >>> long.
    >>>
    >>> The filtering is done with 7 DropDownLists to which data is bound -
    >>> each of the dropdowns has a value and text display - for instance
    >>> ConsultantID, ConsultantName
    >>>
    >>> The DataView looks like this:
    >>>
    >>> TransactionID, ConsultantID, ConsultantName, ManagerID, ManagerName,
    >>> AssetClassCode, AssetClassName, ... etc.
    >>>
    >>> The IDs are generally integers and the Codes - single or double
    >>> characters, only the Names are displayed in the GridView - the IDs and
    >>> Codes are there to speed up filtering.
    >>>
    >>> I've seen some examples on the web.
    >>>
    >>> Should I be following the methods that use delegates for the sorting?
    >>>
    >>> Is FindAll() with a List<T> suitable for all the filtering?
    >>>
    >>> Am I better off using a BindingList<T> rather than a List<T>

    >>

    >
     
    RobinS, Feb 1, 2007
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. tfsmag

    summary footer on paged gridview?

    tfsmag, Mar 14, 2006, in forum: ASP .Net
    Replies:
    0
    Views:
    2,903
    tfsmag
    Mar 14, 2006
  2. Replies:
    2
    Views:
    7,395
    Bruno Alexandre
    Aug 23, 2006
  3. Replies:
    0
    Views:
    414
  4. Aamir Ghanchi
    Replies:
    2
    Views:
    821
    =?Utf-8?B?TGFkaXNsYXYgTXJua2E=?=
    Aug 23, 2007
  5. Richard Pimentel

    Explorer navigation errors with non-paged or large paged DataGrid.

    Richard Pimentel, Dec 31, 2003, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    181
    Richard Pimentel
    Dec 31, 2003
Loading...

Share This Page