Persist Uploaded Files - PostbackTiggers Do Not Work

2 posts, 0 answers
  1. Chi Ming
    Chi Ming avatar
    13 posts
    Member since:
    Apr 2013

    Posted 22 Jul 2014 Link to this post

    Hi, 

    I am trying to use radasyncupload and datepicker controls. I have PostbackTigger property set to Datepicker which does the postback. 

    At first, I uploaded a file using radasyncupload. I just set date to the datepicker control so it did postback that lost uploaded file at this time. I thought the file should be persisted during the postback

    Please assist me with that. 

    Thanks,
    Chi MIng

    <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblERSDate" runat="server" Text="Date Received by ERS" CssClass="control-label col-md-3" AssociatedControlID="dateERSDate">Date Received by ERS<span class="required">*</span></asp:Label>
     
                     <div class="col-md-4">
                         <div class="input-group date form_datetime">
                             <telerik:RadDatePicker ID="dateERSDate" runat="server" AutoPostBack="false" Width="100px" TabIndex="0" OnSelectedDateChanged="dateERSDate_SelectedDateChanged" DateInput-AutoPostBack="true"></telerik:RadDatePicker>
                             <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="dateERSDate" ForeColor="Red" ErrorMessage="Date Received by ERS is Required" ValidationGroup="s3" Display="None"></asp:RequiredFieldValidator>
     
                         </div>
                     </div>
                 </div>
             </div>
             <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblcordate" runat="server" Text="Correspondence Date" CssClass="control-label col-md-3" AssociatedControlID="dateCorDate">Correspondence Date<span class="required">*</span></asp:Label>
     
                     <div class="col-md-4">
                         <div class="input-group date form_datetime">
                             <telerik:RadDatePicker ID="dateCorDate" runat="server" AutoPostBack="false" Width="100px" TabIndex="0">
                                 <ClientEvents OnDateSelected="OnDateSelectedHandler" />
                             </telerik:RadDatePicker>
                             <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="dateCorDate" ForeColor="Red" ErrorMessage="Correspondence Date is Required" ValidationGroup="s3" Display="None"></asp:RequiredFieldValidator>
     
                         </div>
                     </div>
                 </div>
             </div>
             <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblExpedite" runat="server" CssClass="control-label col-md-3" Text="Expedite Request?" AssociatedControlID="btnExpediteYes">Expedite Request?<span class="required">*</span></asp:Label>
     
                     <div class="col-md-4">
                         <telerik:RadButton ID="btnExpediteYes" runat="server" ToggleType="Radio" GroupName="groupExpedite" Text="Yes" ButtonType="ToggleButton" OnClick="btnExpedite_Click" Value="1" TabIndex="0"></telerik:RadButton>
                         <telerik:RadButton ID="btnExpediteNo" runat="server" ToggleType="Radio" GroupName="groupExpedite" Text="No" ButtonType="ToggleButton" OnClick="btnExpedite_Click" Value="0" TabIndex="0"></telerik:RadButton>
                         <asp:CustomValidator ID="Customvalidator1" ErrorMessage="Expedite Request is Required" runat="server" ForeColor="Red" ValidationGroup="s3" ClientValidationFunction="ValidateRadButtons" Display="None" />
                     </div>
                 </div>
             </div>
             <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblDueDate" runat="server" CssClass="control-label col-md-3" Text="Due Date" AssociatedControlID="txtDueDate">Due Date</asp:Label>
     
                     <div class="col-md-4">
                         <telerik:RadTextBox ID="txtDueDate" runat="server" Enabled="false" TabIndex="0"></telerik:RadTextBox>
                     </div>
                 </div>
             </div>
             <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblVAIQ" runat="server" Text="VAIQ Number" CssClass="control-label col-md-3" AssociatedControlID="txtvaiq">VAIQ Number<span class="required">*</span></asp:Label>
     
                     <div class="col-md-4">
                         <telerik:RadTextBox ID="txtvaiq" runat="server" CssClass="form-control" Width="450px" TabIndex="0" MaxLength="15"></telerik:RadTextBox>
                         <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" Display="None" ControlToValidate="txtvaiq" ForeColor="Red" ErrorMessage="VAIQ Number is Required" ValidationGroup="s3"></asp:RequiredFieldValidator>
                         <asp:RegularExpressionValidator
                             ID="RegularExpressionValidator1"
                             runat="server"
                             ControlToValidate="txtvaiq"
                             ValidationExpression="^[a-zA-Z0-9]+$"
                             ErrorMessage="Please enter Valid  VAIQ Number. Only Alphanumeric allowed."
                             ValidationGroup="s3" ForeColor="Red" Display="None">
                         </asp:RegularExpressionValidator>
     
     
                     </div>
                 </div>
             </div>
     
             <div class="row">
                 <div class="form-group">
                     <asp:Label ID="lblupload" runat="server" Text="Upload Files" CssClass="control-label col-md-3" AssociatedControlID="RadAsyncUpload1">Upload Files</asp:Label>
     
                     <div class="col-md-4">
                         <telerik:RadAsyncUpload ID="RadAsyncUpload1" runat="server" Width="450px" OnClientFileUploading="OnClientFileUploading" ValidationGroup="s3" DisablePlugins="True" PostbackTriggers="dateERSDate,btnExpediteYes,btnExpediteNo" OnClientFileUploaded="checkFileNameNewReqeust" ChunkSize="0"></telerik:RadAsyncUpload>
     
                     </div>
                 </div>
             </div>
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 22 Jul 2014 in reply to Chi Ming Link to this post

    Hi,

    This is the expected behavior of the control. When a postback is triggered from a control which ID is contained by PostbackTriggers property all the information for the uploaded files will become available on the server side and the RadAsyncUpload control will stop persisting the uploaded files' information. Please have a look into this help documentation for further information. 

    Thanks,
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top