MaxFileSize, Max Files and Max overall size.

9 posts, 1 answers
  1. Kevin
    Kevin avatar
    8 posts
    Member since:
    Nov 2010

    Posted 23 Dec 2010 Link to this post

    Good morning, I have a problem with a multiple file upload. 1. Is it true that with multiple file selection there is no way to limit a user to say 10 files. 2. Which event should fire when a file is over the MaxFileSize. 3. Is there a way to limit an overall upload size? Ie can you set a max of 2Mbs so a user can only upload 4 x 500Kb files? Thanks in advance, Kevin
  2. Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 29 Dec 2010 Link to this post

    Hi Kevin,

    With respect to your first question, yes, currently there is no way to prevent the user from selecting, say, ten files. The reasons are that neither Silverlight nor Flash provide API for the OpenFileDialog that would allow us to do such thing.

    Regarding your second question, the correct event is FileValidationFailed. I suggest that you visit the following demo for a reference.

    With respect to the last question, currently there is no way to do that with RadAsyncUpload. We will research the possibilities for adding such functionality for future releases.

    Greetings,
    Genady Sergeev
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Kevin
    Kevin avatar
    8 posts
    Member since:
    Nov 2010

    Posted 04 Jan 2011 Link to this post

    Is there any workaround I could use with multiple file selection?

    I dont want users trying to upload 100+ files at a time.

    So I should be able to remove the file from the list of files to upload if the file size is greater than the MaxFileSize?
  5. Answer
    Genady Sergeev
    Admin
    Genady Sergeev avatar
    1596 posts

    Posted 07 Jan 2011 Link to this post

    Hello Kevin,

    This is a valid suggestion. We decided to expose a client OnFilesSelected event with the possibilities to cancel the event or to limit the number of selected files to upload. We will try to push it out as soon as possible, however I can't give you a specific time frame for it.

    Additionally, we are currently preparing a knowledge base article  that shows how to implement combined size validation on the temporary folder. We will release the KB article together with the upcoming Service Pack 2 release.

    Greetings,
    Genady Sergeev
    the Telerik team
    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
  6. Kevin
    Kevin avatar
    8 posts
    Member since:
    Nov 2010

    Posted 07 Jan 2011 Link to this post

    Ok, Thank you.

    Regards,
    Kevin
  7. Sara Muth
    Sara Muth avatar
    4 posts
    Member since:
    Oct 2009

    Posted 24 Sep 2012 Link to this post

    Was this KB article ever released?  I've been unable to find it.

    Thanks! Sara
  8. Plamen
    Admin
    Plamen avatar
    2734 posts

    Posted 27 Sep 2012 Link to this post

    Hello Sara,

     
    The KB was not created because the client OnFilesSelected event was implemented in RadAsyncUpload and one can achieve this validation with it.

    Kind regards,
    Plamen
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  9. _JR_
    _JR_ avatar
    2 posts
    Member since:
    Jun 2013

    Posted 30 Jun 2013 Link to this post

    Hello,
    Is there a way to set the overall max file size upload?
    or is there any validation techniques that will work?

    thanks in advanced.
  10. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 01 Jul 2013 Link to this post

    Hi Jesher,

    Please have a look at this code library project which deals with a similar scenario.

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