This is a migrated thread and some comments may be shown as answers.

RadAsyncUpload1.UploadedFiles.Count always shows 0

1 Answer 261 Views
AsyncUpload
This is a migrated thread and some comments may be shown as answers.
Jagat
Top achievements
Rank 1
Jagat asked on 02 Dec 2016, 08:21 PM

Hi,

I uploaded 3 files using this control. Within  a button click, i want to see the number of files that i uploaded. It always shows 0.

Why am i not getting proper count here?

 

  <telerik:RadAsyncUpload runat="server" ID="RadAsyncUpload1" AllowedFileExtensions =".pdf,.jpg,.jpeg,.txt" 
              MultipleFileSelection="Automatic" BorderStyle="Groove"     >
                                 <Localization Select=" Select a file "    />
                             </telerik:RadAsyncUpload>

 

for (int fileNum = 0; fileNum <= RadAsyncUpload1.UploadedFiles.Count - 1; fileNum++)
{

}

 

 

Thanks

1 Answer, 1 is accepted

Sort by
0
Ivan Danchev
Telerik team
answered on 05 Dec 2016, 11:19 AM
Hello Jagat,

If the files are uploaded without any exceptions you should be able to access the uploaded files' count on the server in the button's click handler. I attached a sample page that shows that by displaying the count in a TextBox.

Regards,
Ivan Danchev
Telerik by Progress
Telerik UI for ASP.NET AJAX is ready for Visual Studio 2017 RC! Learn more.
Tags
AsyncUpload
Asked by
Jagat
Top achievements
Rank 1
Answers by
Ivan Danchev
Telerik team
Share this question
or