RadAsyncUpload Clear Items using Serverside Code

2 posts, 0 answers
  1. Liby George
    Liby George avatar
    4 posts
    Member since:
    Jan 2014

    Posted 10 Oct 2014 Link to this post

    I am using RadAsyncUpload to upload files. I have a 'Cancel' button which the user can click anytime after selecting the files (see the attached image). I want to clear the selected files - or in other words reset the RadAsyncUpload Control when 'Cancel' button is clicked. I am doing some other checks when this button is clicked so I don't want to do this on client side. Please advice. 

    Thanks
  2. Boyan Dimitrov
    Admin
    Boyan Dimitrov avatar
    1746 posts

    Posted 15 Oct 2014 Link to this post

    Hello,

    Please include the following line of code in your click handler for the "Cancel" button.
    //JavaScript
    $telerik.$(".ruInputs li .ruRemove").click()

    This will go through the files <li> elements and click on the "Remove" link.

    Regards,
    Boyan Dimitrov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

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