A Working, Complete Row Highlightable DataGrid Demo

This demo fixes the final problems in FireFox. It should work with both FireFox 1.0 and IE 6.0. Enjoy!


First NameLast NameEmail
BugsBunnybbunny@wb.com
MickeyMousemmouse@disney.com
DonaldDuckdduck@disney.com
DanMarinodmarino@dolphins.com
SteveStchursstchur@yahoo.com


Source Code
<style>
  tr.row:hover, tr.over td { background-color: #ffccff; }
</style>

<asp:DataGrid id = "myGrid"
							CellPadding = "5"
							AutoGenerateColumns = "false"
							Font-Name = "verdana"
							Font-Size = "10pt"
							runat = "server">
									
	<HeaderStyle BackColor = "#336699" ForeColor = "#ffffff" Font-Bold = "true"  />
	<AlternatingItemStyle BackColor = "#eeeeee" CssClass="row" />
	<ItemStyle CssClass="row"  />
									
	<Columns>
		<asp:BoundColumn HeaderText = "First Name" DataField = "firstName" />
		<asp:BoundColumn HeaderText = "Last Name" DataField = "lastName" />
		<asp:BoundColumn HeaderText = "Email" DataField = "emailAddress" />
	</Columns>
</asp:DataGrid>
		

[Return to the article...]