Clear upload control filelist

2 posts, 0 answers
  1. Sunitha
    Sunitha avatar
    1 posts
    Member since:
    Feb 2012

    Posted 25 Oct 2012 Link to this post


    I am looking for a way to clear the files listed in the control after successful / unsuccessful upload . I need the conrol to look just like the way it looks before files are selected.  I would need a way to clear them programmatically any help is greatly appreciated.


  2. Pavel R. Pavlov
    Pavel R. Pavlov avatar
    1237 posts

    Posted 30 Oct 2012 Link to this post

    Hello Sunitha,

    To achieve you issue you can use the UploadFinished and FileUploadFailed events of the RadUpload control. When some of these events fire you can call the CalcelUpload method  and this will bring back the start view of the control. Here is a sample XAML code:

    <telerik:RadUpload x:Name="xUpload" UploadFinished="xUpload_UploadFinished" FileUploadFailed="xUpload_FileUploadFailed"/>

    And this is the code-behind:

    private void xUpload_UploadFinished(object sender, System.Windows.RoutedEventArgs e)
    private void xUpload_FileUploadFailed(object sender, FileUploadFailedEventArgs e)
    Hope this is what you are looking for.

    Pavel R. Pavlov
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top