DataGrid and GridView

  • Thread starter Thread starter Toni
  • Start date Start date
T

Toni

In DataGrid and GridView I can't use paging and sorting. I am connected to
database with code, not visual. Can I use paging and sorting if I populate
data to grid with code, or I need to drag and drop connection, dataset,
datatable etc.
 
In DataGrid and GridView I can't use paging and sorting. I am connected to
database with code, not visual. Can I use paging and sorting if I populate
data to grid with code, or I need to drag and drop connection, dataset,
datatable etc.

What do you mean when you say you "can't use paging and sorting"? Are
there errors? Does the paging footer display? Or does .NET reach out
and prevent you from clicking your mouse?

It's just a matter of turning on paging and sorting properties for
that Gridview.
 
What do you mean when you say you "can't use paging and sorting"? Are
there errors? Does the paging footer display? Or does .NET reach out
and prevent you from clicking your mouse?

It's just a matter of turning on paging and sorting properties for
that Gridview.

Paging and Sorting properties are turned on. In GridView I get error. In
DataGrid there is no reaction. I can click on header captions but nothing. I
have caption for next and previous page but when I click, page is reloaded
but not sorted.
 
Paging and Sorting properties are turned on. In GridView I get error. In
DataGrid there is no reaction. I can click on header captions but nothing. I
have caption for next and previous page but when I click, page is reloaded
but not sorted.

Hi Toni

In addition to enabling Paging and Sorting have you defined sort
expressions for the columns? I know that when creating a GridView
using visual tools the sort expression defaults to the column value,
but in non-visual handling the result may be unpredicatable.

HTH
 
Back
Top