C# .NET - horizontal and vertical scroll bar with fixed header in repeater contr
Asked By deepi singh on 28-Dec-11 01:08 AM
horizontal and vertical scroll bar with fixed header in repeater control?
see this below link http://www.dotnetspider.com/resources/2301-Scrollable-Repeater-control-with-fixed-column-Header-Auto-Scrollbar.aspx
where i have to call tht synHeader function call ?
Jitendra Faye replied to deepi singh on 28-Dec-11 01:13 AM
Try this CSS for Header-
<style type="text/css">
.header
{
font-weight:bold;
position:absolute;
background-color:White;
}
</style>
<asp:Repeater id="Repeater1" runat="server">
<HeaderTemplate CssClass="header" Height="20px">
<table border="1">
</HeaderTemplate>
------------
------------
Try this and let me know.
deepi singh replied to Jitendra Faye on 28-Dec-11 01:26 AM
i have master page in my aspx page..how to apply css class?
smr replied to deepi singh on 28-Dec-11 01:35 AM
hi
apply
css for this
. Define class
.Freezing in Stylesheet:
|
|
|
|
.Freezing
{
position:relative ;
top:expression(this.offsetParent.scrollTop);
z-index: 10;
} |
follow
http://forums.asp.net/t/1028152.aspx
dipa ahuja replied to deepi singh on 28-Dec-11 02:57 AM
<script type="text/javascript" language="javascript">
function fixHeader() {
var t = document.getElementById("table");
var thead = t.getElementsByTagName("thead")[0];
var t1 = t.cloneNode(false);
t1.appendChild(thead);
tableHeader.appendChild(t1)
}
window.onload = fixHeader
</script>
http://dotnetslackers.com/Community/blogs/kaushalparik/archive/2008/06/28/vertically-scrollable-repeater-with-fixed-headers.aspx
Jitendra Faye replied to deepi singh on 28-Dec-11 03:38 AM
I master page also you can write CSS, on top of the page.
<style type="text/css">
.header
{
font-weight:bold;
position:absolute;
background-color:White;
}
</style>