"The selected file was not found." - InfoPath 2007 Web form
What you mean 'not found'?
grrrrrrrrrrrrrrr
You can either apply that to me thinking that attaching a file to my InfoPath form would be easy or MS for allowing such a nasty insidious bug to crawl out into production.
Here's the issue. I have an InfoPath form running under MOSS Enterprise forms services. Upon this form I have a couple of file attachment controls. One would thunk that given that file attachment controls seem to have been a part of HTML since the mid 1990's that this should be a totally elementary operation.
Heh, think again.
I found this out the hard way when, after browsing to my file and pressing the Upload button I was met with a rather curt 'The Selected File was not found' error message.
here is sol'n Add the attribute enctype="multipart/form-data" to this tag and save.
I haven't really found a suitable solution / explanation for this, but there is a workaround. You can edit the html where you are using InfoPath add the following javascript code into the file:
<script type="text/javascript">
aspnetForm.encoding = "multipart/form-data";
</script>
Comments
Anonymous
April 22, 2009
Many Thanks for this fix, worked like a charm. I was using this on a web part page so just put your code in a hidden webpart using content editor web part. Thanks again!Anonymous
January 07, 2010
You've saved my day! Thanks ;)Anonymous
May 17, 2012
Thanks. it worked