改一下aspx文件

<asp:listbox
放到
<form runat=server中

解决方案 »

  1.   

    因为ListBox是asp.net的web控件,所以要有runat=server支持
      

  2.   

    在你的aspx页面内,
    <body>
    <form id="Form1" method="post" runat="server">
    <FONT face="宋体">
    ………………………………………………………………………………
    写入类似<asp:ListBox Runat="server" id="aaa"></asp:ListBox>………………………………………………………………………………
    </form>
    </body>
      

  3.   

    服务器控件必须放到runat=server
    HTML不需要runat=server