Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

gridview paging disappear

Posted on 2007-11-19
3
Medium Priority
?
774 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 1000 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

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

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

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Are you ready to place your question in front of subject-matter experts for more timely responses? With the release of Priority Question, Premium Members, Team Accounts and Qualified Experts can now identify the emergent level of their issue, signal…
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …
Suggested Courses

963 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