File Filter Flaw

4 posts, 0 answers
  1. SchaF
    SchaF avatar
    28 posts
    Member since:
    Jan 2012

    Posted 16 Mar 2012 Link to this post

    I recently discovered a flaw with the file upload filter being used with the upload control. I have an upload control set to allow only .pdf and .tif files, so when I click browse to search for files, the only ones that show up as being allowed to be uploaded are .pdf and .tif. However, I I decide to type the file name in, it will allow me to upload whatever I want from .txt, .xaml, .xml or even files with no extensions.

    Any reason why this would be happening?
  2. Alex Fidanov
    Alex Fidanov avatar
    636 posts

    Posted 19 Mar 2012 Link to this post


     This filter is only how the files are shown in the Open File Dialog. The filter does not prevent adding items in the Upload control that do not meet the filter's criteria. If you want to allow uploading item of only certain types or extensions, you can use the RadUploadItem.Validate event. You can see how to use it here.

    Kind regards,
    Alex Fidanov
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. DevCraft R3 2016 release webinar banner
  4. Richa
    Richa avatar
    4 posts
    Member since:
    Jul 2012

    Posted 10 Jul 2012 Link to this post


    But the code given given in link is not working. It is giving error that
    No overloaded method AddHandler accept two arguments.
  5. Petar Mladenov
    Petar Mladenov avatar
    2882 posts

    Posted 12 Jul 2012 Link to this post

    Hello Richa,

     Can you please confirm that you have added a reference to the Telerik.Windows namespace?
    If yes, is it possible for you to send us a new support ticket with a project in which your issue is reproducible? Thank you in advance. 

    Kind regards,
    Petar Mladenov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Back to Top