protected void GridView1_RowCreated(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowIndex != -1)
{
e.Row.Attributes.Add("onmouseover", "this.style.backgroundColor='#bfd4e6'");
e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor='#efefef'");
string id = e.Row.Cells[1].Text;
e.Row.Attributes.Add("ondblclick", "window.open('2.asp?pipe_num="+id+"')");
} } 无法得到id???????id为空?????
{
if (e.Row.RowIndex != -1)
{
e.Row.Attributes.Add("onmouseover", "this.style.backgroundColor='#bfd4e6'");
e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor='#efefef'");
string id = e.Row.Cells[1].Text;
e.Row.Attributes.Add("ondblclick", "window.open('2.asp?pipe_num="+id+"')");
} } 无法得到id???????id为空?????
解决方案 »
- 一个窗口关闭时如何设置另外一个窗口enable=true?
- c# 2008
- 计算类似格式的"2008-8-4 0:00:34" 和 "2008-8-4 0:14:54" 的时间差 具体怎么写
- text文本框为空或者不是数字时候如何在计算时候不计算,就像excel那样。
- 关于ServicedComponent ,100分
- “fsdy2000(乡愁) 写的串口发送有问题,” +++++100问题!超级送分!! 串口发送数据出现乱码++++++
- Web Services问题
- 装箱可以理解为对象的转换吗?
- 算法问题.
- 如何实现窗体的重载
- Asp.net有主函数main么,怎么设置首页?
- 程序执行时间有点长,我想做个“数据更新中,请稍候。。。”的提示窗体
if(e.Row.RowType == DataControlRowType.DataRow)
{
string id = e.Row.Cells[1].Text;
}