(please note: this question isn't about the validity of allowing .exe files to be uploaded - We know the risks, and have read all the alternatives. For us, using .exe is critical, as we have decades of files that need to be available to our customers)
I'm building a list that will feed a custom web part that will provide customers with access to our software. I've configured the SharePoint web application to no longer block .exe files, and this works well when using the lists default form.
However, when I create a custom form for the list using InfoPath (via the "Customize Form" icon in the ribbon), and publish my form back to SharePoint, there's a change in behavior for attachments:
with the default form, when I click "Attach File" the file is attached immediately, and the form shows the attachment as "c:\fakepath\myfilename.exe". Once I've completed the other fields in the form and save the item, the file is uploaded. Once the file is uploaded the form closes and my list refreshes to show the new item
with the custom form, I click "Click here to attach a file" (this text/button change was automatic when I began customizing the form), but rather than attach the file immediately and upload when the item is saved, the file is uploaded immediately and then I'm told that .exe files are blocked.
The big difference I see is that with the default form the ability to attach a file is part of the "New Item" toolbar, but once I edit the default form, even if I change nothing, the attachment control moves INTO the form and then starts blocking file types.
Does anyone know a way around this? We really want to customize the form, as we have lots of columns in the list, but this is stopping us being able to do that.