Asp.net fileupload control hasfile always false for docx files

Go To StackoverFlow.com

0

This has inexplicably started happening within the last 6 months or so. This same code used to work with .docx files:

<asp:FileUpload ID="FileUploader" runat="server" BackColor="#620D14" />

if (FileUploader.HasFile)
    ....

Any idea what has started happening? Or can someone at least recommend a open source or a cheap alternative control to use? I really don't like this thing anyway because it is impossible to style...

2012-04-04 02:31
by Darren


1

This other question might help you.

In relation to an alternative for the FileUpload control I'd recommend you to try Uploadify. It worked great for me and it's much more flexible than the built in file upload control.

2012-04-04 02:37
by Claudio Redi


5

if your docx file is empty fileupload.Hasfile returns false but if you open docx file and save something in, you get true from fileupload.HasFile

2012-11-15 12:30
by Kamil A.