FileUpload1.HasFile is always returning false

前端 未结 3 1902
闹比i
闹比i 2021-01-14 05:34

I am uploading file using ASP.net File upload control. My FileUpload1.HasFile is always returning false.

if (FileUpload1.HasFile)
        {
            DBOpe         


        
3条回答
  •  独厮守ぢ
    2021-01-14 06:20

    I know this post if old, but I found that if the file is empty [ 0 KB ] then it will return false as well. There has to be something in the file in order for .HasFile to acknowledge it.

提交回复
热议问题