C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Forums » .NET » HTML »

Div - overflow:scroll problem


Posted Date: 30 Sep 2009      Posted By: nitkumr      Member Level: Bronze     Points: 1   Responses: 3



Hi,
In this i need the scroll to work only in the body of the table and the header has to remain in the same postion when i scroll.
But problem here is when i give overflow:scroll only in the tbody its not working.

I want the heading to remain in the same postion when i scroll.
Actually the "overflow:scroll" is not workin in the "<tbody>" only in div it is working.

Can you give best solution for this problem?

<div style="height: 250px;border-width:2px;border-color:#0066cc;border-style:solid">
<table border="3" bordercolor="gray" align="center" width="100%" id="displayTable" dt>
<thead>
<tr> <Th></Th>
<th>column 1</th>
<th>column 2</th>
<th>column 3</th>
<th>column 4</th>
<th>column 5</th>
<th>column 6</th>
</tr>
</thead>
<tbody style="font-size:80%;height:100%;overflow:scroll">
</tbody>
</table>
</div>


Thanks





Responses

Author: Ganesh Babu    30 Sep 2009Member Level: GoldRating: 2 out of 52 out of 5     Points: 2

A great javascript tool available free of cost which will support all the browsers.

Get the link from my blog:

http://asganesh.wordpress.com/2009/08/29/freeze-html-table-header/

Hope this will helpful to you.

Regards,
Ganesh.
http://asganesh.wordpress.com



Author: Dharmendra Kumar    05 Oct 2009Member Level: GoldRating: 2 out of 52 out of 5     Points: 2

use the following code in the style of the div

<div style="overflow:auto">

</div>



Author: diyaa    14 Nov 2009Member Level: SilverRating: 2 out of 52 out of 5     Points: 2

use the following code in the style of the div tag
<div style="overflow:scroll"></div>
thanx n rate me is it working?



Post Reply
You must Sign In to post a response.
Next : Div - overflow:scroll problem
Previous : Reg: problem on meta tag
Return to Discussion Forum
Post New Message
Category: HTML

Related Messages



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use