Click here to Skip to main content
11,933,180 members (63,059 online)
Rate this:
Please Sign up or sign in to vote.
See more: C# ASP.NET CSS C#4.0
I need a web page to scroll up to gridview header and then scroll only gridview there any possibility to do that???
Posted 26-Feb-13 9:36am
Sergey Alexandrovich Kryukov 26-Feb-13 15:03pm
Did you ever try to find some available solution? People do such things all the time...

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Yes, you can do it with CSS. There are many solutions; for example, see this CodeProject articles:
How to Fixed GridView's Header and Footer when scrolling?[^],
Grid View with Fixed Header[^].

There are also very many solutions you can find on the Web, just do the search.

sundarpks 26-Feb-13 15:08pm
i have already tried retains only gridview header and footer...but i need to scroll the page up to gridview header and retain gridview header as well as other page contents and then scroll only gridview contents...
Sergey Alexandrovich Kryukov 26-Feb-13 15:28pm
I don't see the difference. Your comment does not explains to it me. Perhaps I'll understand if you explain it in a way more detailed manner.
sundarpks 26-Feb-13 15:45pm
i have some contents above that gridview...the page should scroll up to that gridview header...when the scroll reaches gridview header, header should get retained and then scroll only gridview contents...

Hope u clear with this...r u need further explanation???
Sergey Alexandrovich Kryukov 26-Feb-13 15:50pm
Still not clear. If the above is not a part of the gridview, don't you think this is not a consistent requirement?
sundarpks 26-Feb-13 16:17pm
client asked so...they need some contents above that gridview....

In my web page i have some contents...below that contents there is a gridview...we have to scroll the page to view the grid...when the gridview reaches the page top, the gridview header should get fixed and then gridview contents should scroll...
Sergey Alexandrovich Kryukov 26-Feb-13 16:41pm
I am not asking where it comes from, and not questioning having this content and access to it, I'm questioning the consistency. You were asking about the grid view, and not it's something about "under". You need to describe the behavior in detail (especially because it looks pretty unusual), and think about the consistency.
Sundar PKS 27-Feb-13 2:23am
I think there is no problem with u said i accept its pretty unusual...i searched all over the web and i didnt get any available solution for of my friend sent me a html page for my requirement which works with table instead of gridview...i made some changes in that code and finally got the solution...

you can implement my solution for better understanding...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web04 | 2.8.151126.1 | Last Updated 26 Feb 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100