This is my first time using the AsyncFileUpload so please tell me if I'm missing something obvious. I have it working in the sense that one can upload a file and I can save it to the correct place and all that stuff.
The implementation I am using it on is a form that sends an email, one that may or may not have an attachment. The attachment isn't a required field, but other form fields are in fact required.
If one goes to the bottom of the form and uploads a file, without doing anything else, the file gets saved in my attachments folder on the web server. However, it doesn't logically make sense to me that one should be able to do that without first filling out a valid form. It seems like what this is going to promote is a lot of files hanging around from those who already uploaded a file but didn't bother to fill out the rest of the form correctly.
There is an OnClientUploadStarted event, but that's too late. It seems like there should be an OnClientBeforeUpload so form validation can take place prior to a file getting physically saved on the server. Am I missing something?
So I guess what I could do is do server side form validation in the OnUploadedComplete event before calling the controls SaveAs method, is that really the only way to do it? Where is the file "uploaded" to
View Complete Post