this.Label1.Text = "推荐给好友" + Convert.ToString("http://localhost/haoyou/beiyaoqing.aspx?id=" + sql);
我上面得到一个字符串,并且是一个连接地址,但是连接地址是一个字符串类型的,并且不能点,我想要的效果是我可以点着个连接地址,并且着个连接地址是那种可以变色的那种

解决方案 »

  1.   

    this.Label1.Text = "推荐给好友<a href='" + Convert.ToString("http://localhost/haoyou/beiyaoqing.aspx?id=" + sql)+"' target='_blank'>"+Convert.ToString("http://localhost/haoyou/beiyaoqing.aspx?id=" + sql)+"</a>"; 
      

  2.   


    this.Label1.Text = "<a href='http://localhost/haoyou/beiyaoqing.aspx?id=" + sql+"'>推荐给好友</a>"; 
      

  3.   


    this.Label1.Text = "<a href='http://localhost/haoyou/beiyaoqing.aspx?id=" + sql+"'>推荐给好友</a>"; 
      

  4.   

    this.Label.Text="<a href='地址'>推荐给好友</a>"