I have a standard AjaxFileUpload control
<asp:AjaxFileUpload ID="upManager" CssClass="fileUpload" runat="server" OnUploadComplete="upManager_UploadComplete" />
And instead of them having to press Upload, I just want the file to upload automatically once they have selected the file. Is there a way to do this?
you're right. Just replace it with
Add reference to this script to
Scripts
collection ofToolkitScriptManager
control or just put it at very bottom of page:Works well from console at this page: AjaxFileUpload Demonstration
Also, in my opinion should be better to tweak ACT sources and add new property like
UploadAutomatically
to this control. Let me know if you'll prefer this option and need additional details about how to to such staffUPDATED: try this script for new AjaxFileUpload (must work for new and old versions but not tested yet)
this works in the newest control toolkit