GridView模版列中显示QQ是否在线问题..在线等结帖!
如题,我要在GridView1_RowDataBound()事件中给模版列加入下面这段话怎么加?
<a target=blank href=http://wpa.qq.com/msgrd?V=1&Uin=15111608&Menu=yes> <img SRC=http://wpa.qq.com/pa?p=1:15111608:1 alt= "点击这里给联系站长 " border= "0 "> </a>
img中的QQ号码用label1.text代替,代码要怎么写?超链接怎么加的?
------解决方案-------------------- <%# Eval( " <a target=blank href=http://wpa.qq.com/msgrd?V=1&Uin={0}&Menu=yes> <img SRC=http://wpa.qq.com/pa?p=1:15111608:1 alt= "点击这里给联系站长 " border= "0 "> </a> ", "QQ号码的字段名 ")%>
或者
<%# Eval( "QQ号码的字段名 ", " <a target=blank href=http://wpa.qq.com/msgrd?V=1&Uin={0}&Menu=yes> <img SRC=http://wpa.qq.com/pa?p=1:15111608:1 alt= "点击这里给联系站长 " border= "0 "> </a> ")%>
忘了顺序,没VS试验,你自己看是哪个吧