htmlInput control doesn't work with Access file?
In my asp.net app, I used an htmlInput control to upload either Excel, Access or text files. Both Excel and text file
types work, but not Access file type. I got error message saying Can't find server or DNS error.
If I don't click on the Browse button of the control, the app works fine. It doesn't work if I click on it. I guess that
means it's not a permission issue.
Code:
Try
txtUpload.PostedFile.SaveAs(sFullPath)
lblErrorMessage.Text = "Upload of File " & sFile & " to " & sFullPath & " succeeded"
uploadSuccessed = True
Catch Ex As Exception
lblErrorMessage.Text = "Upload of File " & sFile & " to " & sFullPath & " failed for the following reason:
" & Ex.Message
uploadSuccessed = False
Finally
lblErrorMessage.Font.Bold = True
lblErrorMessage.Visible = True
End Try
Thanks for your help!
|