onmouseover="javascript:window.open ('spring.aspx?src='<%# (String)DataBinder.Eval(Container,"DataItem.filepath")%>'', 'newwindow', 'height=400, width=400, top=100,left=100, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')" ,写面这句报错,请问如何写,在线等.
{
//如果是数据项并且是交替项
if(e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem)
{
//添加自定义属性,当鼠标移过来时设置该行的背景色为"6699ff",并保存原背景色
e.Item.Attributes.Add("onmouseover","currentcolor=this.style.backgroundColor;this.style.backgroundColor='#6699ff'");
//添加自定义属性,当鼠标移走时还原该行的背景色
e.Item.Attributes.Add("onmouseout","this.style.backgroundColor=currentcolor"); }
}
因为open属性都是以“”来标
是什么内容啊。估计是你这个的问题了,我这里正常
加?src=<%# DataBinder.Eval(Container.DataItem,"filepath")%>试试你!!!