You need to sign in to do that
Don't have an account?

Anyway to disable a forms submit button when inputfile is used?
As you may know, forms that have inputfile tags can't use status indicators. Also, buttons that submit forms where files are uploaded can't have javascript that runs onclick AND have apex methods called.
So, how do you have a button that gets disabled upon click while files upload? I ask because if a user isn't patient and clicks submit a 2nd time, they will get an error and have to start over.
Thanks for any ideas or examples.
what about onsubmit event inside the <apex:form tag?
Regards
I tried that and it calls the onsubmit javascript but then the apex method (to save the record and attach the files) doesn't get called.
I've tried this code
And the javascript works :S, and after that, the method action (that the only thing that does is to redirect me to the homepage) also works
SeAIVa - thanks for the reply.
I forgot to mention that my form is a wizard that uses mutiple output panels with buttons. These output panels get rendered, then once completed / validated they are hidden and the other panels (one at a time) get rendered.
Per salesforce support and best practices, this is all done in one form.
When I tried your example, the first output panel failed to hide and the 2nd failed to appear - it just depressed the button.
I even tried breaking up the output panel with the input files into its own form and the behavior was the same.