Hi,
Insert a div tag inside DataGrid Tag with the following name "div-datagrid"
Declare a Sytle Tag something like this,
<style>
DIV#div-datagrid { OVERFLOW: auto; WIDTH: 420px; HEIGHT: 200px }
.lockrow
{
TOP: expression(document.getElementById("div-datagrid").scrollTop-2);
POSITION: relative;
}
</style>
In ItemDataBound Event of the datagrid,
If e.Item.ItemType = ListItemType.Header Then
For Each MyCell As System.Web.UI.WebControls.TableCell In
e.Item.Cells
MyCell.CssClass = "lockrow"
Next
End If
"Wasco" wrote:
Hi All,
somebody knows how can I implement a scrollable datagrid?
I made one used DIV tag and the tricks of a datagrid for title and
another for contents but I'm not satisfied.
Thanks!!