RadUpload in FormView

Thread is closed for posting
2 posts, 0 answers
  1. Ahmed
    Ahmed avatar
    1 posts
    Member since:
    May 2013

    Posted 27 May 2013 Link to this post

    i'm using radupload in formview  control asp.net 

    why UploadedFiles.Count always 0??!!

    otherwise when i use RadUpload without formview it's running.

    Thanks

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 27 May 2013 Link to this post

    Hi,
    I have tried the following code snippet to get the count and it worked as expected.
    ASPX:
    <asp:FormView ID="fvDetail" runat="server" DataKeyNames="CustomerID" DataSourceID="SqlDataSource1" DefaultMode="Edit">
     <EditItemTemplate>
       <telerik:RadUpload ID="RadUpload1" runat="server">
       </telerik:RadUpload>
     </EditItemTemplate>
    </asp:FormView>
    <asp:Button ID="button1" runat="server" Text="click" OnClick="button1_Click" />
    C#:
    protected void button1_Click(object sender, EventArgs e)
     {
        RadUpload upload = (RadUpload)fvDetail.FindControl("RadUpload1");
        int count = upload.UploadedFiles.Count;
     }
    Hope this will help you.
    Thanks,
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top