Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. Parser Error Message: Server tags cannot contain <% ... %> constructs.Source Error: 
Line 151: <td class="nbtext" style="HEIGHT: 54px">Attachment:
Line 152: </td>
Line 153: <td class="nbtext" style="HEIGHT: 32px" runat="server"><a href="<%=Session["qanumber"]%>" runat="server" target=_blank id="attachmentfile"><asp:label id="attachment" runat="server"></asp:label></a></td>
Line 154: </tr>
Line 155: 这是什么原因阿??
 

解决方案 »

  1.   

    <a href="<%=Session["qanumber"]%>" runat="server" target=_blank id="attachmentfile">
    要么把里面的runat="server"去掉,要么不在aspx里设置href属性,在.cs里设置这个属性
      

  2.   

    <a href='<%=Session["qanumber"]%>' target=_blank id="attachmentfile">
    这样看看
      

  3.   

    <a href="<%=Session["qanumber"]%>" runat="server" target=_blank id="attachmentfile">修改成单引号<a href ='<%=Session["qanumber"]%> '
      

  4.   

    但是如果要在.cs里面设置属性
    这个<a></a>是个什么控间阿?
      

  5.   

    要么把里面的runat="server"去掉,要么不在aspx里设置href属性,在.cs里设置这个属性