Embed AjaxFileUpload as a first-class form field alongside TextBox, DropDownList,
and Button controls. The uploaded file ID is stored in a HiddenField and submitted with the postback -
so the server-side FileUploaded event and the form Submit stay independent and
both have everything they need. This pattern works equally well with any of the v5.2 transport strategies
(classic, chunked, S3, Azure, GCS, tus) without changing the C# code.
<asp:TextBox ID="txtName" runat="server" CssClass="form-control" />
<asp:DropDownList ID="ddlCategory" runat="server" CssClass="form-select">
<asp:ListItem Text="General" Value="general" />
</asp:DropDownList>
<au:AjaxFileUpload ID="Uploader1" runat="server"
AutoUpload="true"
ShowProgress="true"
OnClientUploadComplete="onFileUploaded" />
<asp:HiddenField ID="hdnFileId" runat="server" />
<asp:Button ID="BtnSubmit" runat="server" Text="Submit"
CssClass="btn btn-primary" OnClick="BtnSubmit_Click" />