make sure you have enctype on the form:<form runat=server enctype="multipart/form-data">
 <input type=file id="loFile" runat=server></form>

解决方案 »

  1.   

    to:思归大哥
    你写的我已经写了
    我用try捕获得到loFile.PostedFile==null
      

  2.   

    what is in loFile.Value? show more code?
      

  3.   

    <form id="WebNewMenu" method="post" encType=" multipart/form-data" runat="server" onclick="Page_Load">
    <TD><FONT face="宋体">图片名称:</FONT></TD>
    <TD><FONT face="宋体"><INPUT id="loFile" type="file" runat="server"></FONT></TD>
    <TD style="WIDTH: 82px"><FONT face="宋体"></FONT></TD>
    <TD><FONT face="宋体">
    </form>
      

  4.   

    我是根据这里
    http://xml.sz.luohuedu.net/xml/ShowDetail.asp?id=2A5DD7C6-A45A-48AB-A2E8-342A29F17506
    把VB改为C#就出错了
      

  5.   

    encType=" multipart/form-data" 
          ^^^^^^^^ you have a space here
    ==>
    encType="multipart/form-data"