Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Gridview and Content Page

Status
Not open for further replies.

SASCons

Programmer
Apr 14, 2006
6
US
I am using a Master page with multiple content pages. The master page is laid out using tables. I have a page that contains a content control. When I try to add paging to the gridview I get an error message saying that paging does not support server-side controls. How can I fix this issue?


Thanks
 
How are getting the data into the gridview? SQLDataSource - ObjectDataSource or binding manually? If manually are you binding to a dataset or to a reader?

Hope everyone is having a great day!

Thanks - Jennifer
 
I am binding the data manually using a Class object that runs a stored procedure from SQL 2005 and the function returns the data as sqldataadapter which is then set to the datasource and then the control.databind is called. If I take the same control and put it on a basic webform, the data is returned without an error.

Thanks
Scott
 
I also bind the data manually but I use the dataset instead of the adapter. The paging worked in a content page for me. Maybe you could give that a try.

Hope everyone is having a great day!

Thanks - Jennifer
 
I did what you said to try. Only part of the paging works. I set the gridview to only display 10 records at a time. When I load the page up I only see 10 records with a 1 at the bottom of the grid. There are a total of 51 records that should show up. There should be 6 numbers at the bottom of the grid. Here is my code that I am using

Dim dsProducts As New Data.DataSet
dsProducts = catalog.GetProductsInDepartment(departmentID)
Me.ItemsGridView1.DataSource = dsProducts
Me.ItemsGridView1.DataBind()
I tried using just a basic sqldataadapter and I still only show up the first 10 records with no other wayt o see the other records

Thanks - Scott
 
I am not sure but you might check the PagerSettings make sure that is setup correctly.

Hope everyone is having a great day!

Thanks - Jennifer
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top