要产生的html代码如下:
<TR onmouseover="currentcolor=this.style.backgroundColor;this.style.backgroundColor='#e3e5fc';this.style.color='#ff0000'" onmouseout="this.style.backgroundColor=currentcolor;this.style.color=''">
<TD>李小明</TD>
<TD>男</TD>
</TR>
<TR onmouseover="currentcolor=this.style.backgroundColor;this.style.backgroundColor='#e3e5fc';this.style.color='#ff0000'" style="BACKGROUND-COLOR: #f0f0f0" onmouseout="this.style.backgroundColor=currentcolor;this.style.color=''">
<TD>邱少云</TD>
<TD>男</TD>
</TD></TR>
<TR onmouseover="currentcolor=this.style.backgroundColor;this.style.backgroundColor='#e3e5fc';this.style.color='#ff0000'" onmouseout="this.style.backgroundColor=currentcolor;this.style.color=''">
<TD>李小明</TD>
<TD>男</TD>
</TR>
<TR onmouseover="currentcolor=this.style.backgroundColor;this.style.backgroundColor='#e3e5fc';this.style.color='#ff0000'" style="BACKGROUND-COLOR: #f0f0f0" onmouseout="this.style.backgroundColor=currentcolor;this.style.color=''">
<TD>邱少云</TD>
<TD>男</TD>
</TD></TR>
解决方案 »
- 新手问题 转换问题
- asp页面传值,用什么方法好点?急求 !!!在线等 ,谢谢!!!
- 类库项目中怎样才能显示所引用的DLL文件?
- 如何获取DataList中<ItemTemplate>里的LinkButton中的Text值
- 大家有没碰到过这类问题.
- 0分求助,穷啊
- 求解决ASP.NET 服务器数据7-zip解压缩问题,急,急,急!恳请高手帮忙
- 要在DropDownList下拉框里绑定数据库中某个表的某个字段,该如何用语句实现!请指教!
- 奇怪:这段代码在windows Form应用中能取到打印机,但在web form中却不行??(在线等待!~)
- 如果大家用动网论坛的话,请问发帖子时的留言预览如何用ASP.Net实现~!
- 一个注册的问题
- SQL传参
if (e.Item.ItemType==ListItemType.Item | e.Item.ItemType==ListItemType.AlternatingItem)
{
e.Item.Attributes.Add("onmouseover","c=this.style.backgroundColor;this.style.backgroundColor='#DFDFDF';oldstyle = this.style.color; this.style.color='blue';");
e.Item.Attributes.Add("onmouseout","this.style.backgroundColor=c;this.style.color=oldstyle;");
}