Solved

gridview paging disappear

Posted on 2007-11-19
3
766 Views
Last Modified: 2008-02-01
Can anyone can explain to me why if I render the ID column invisible on the gridview  using this code...

the paging row disappear (so the paging is notdisplayed)
And how can I then not render the ID but keeping the paging ??

Thanks

Protected Sub GridView1_RowCreated(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GridView1.RowCreated

        e.Row.Cells(0).Visible = False

    End Sub

Open in new window

0
Comment
Question by:brillox
3 Comments
 
LVL 4

Expert Comment

by:iuconStefan
ID: 20313567
try this

If e.Row.RowType = DataRow e.Row.Cells(0).Visible = False

to hide only datarows. Otherwise also Header, Footer and Pager are affected
0
 
LVL 11

Accepted Solution

by:
DotNetThinker earned 250 total points
ID: 20313886
Can't you just set the ID column to Visible="false" in the markup?
0
 

Author Comment

by:brillox
ID: 20314286
Hi Dotnetthinker,

Yes you are right :)
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
ASP.net VB.net Email  a webpage 3 30
Re-position the objects 7 96
Vb.net dynamic formulas in runtime 11 61
Syntax Error 2 44
This article discusses the ASP.NET AJAX ModalPopupExtender control. In this article we will show how to use the ModalPopupExtender control, how to display/show/call the ASP.NET AJAX ModalPopupExtender control from javascript, how to show/display/cal…
In an ASP.NET application, I faced some technical problems. In this article, I list them out and show the solutions that I found.  I hope it will be useful. Problem: After closing a pop-up window, the parent page should be refreshed automaticall…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now