Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. openfiledialog with filter property

openfiledialog with filter property

Scheduled Pinned Locked Moved ASP.NET
sysadmin
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Y Offline
    Y Offline
    yogesh_kumar_agarwal
    wrote on last edited by
    #1

    Hi All, i Have made a web application, working fine in WINDOWS and MAC, but in my application i have a file upload option by which, user can select file and upload it on server. For this i use openfiledialog to select files and use filter to filter only allowed file types in selection. the filter is like :

    dlg1.filter=Files Allowed(*.pdf;*.doc;*.docx;*.txt;*.xls;*.xlsx;*.ppt;*.pptx;*.bmp;*.jpg;*.jpeg;*.gif;*.tif;*.tiff;*.png)|*.pdf;*.doc;*.docx;*.txt;*.xls*;*.xlsx;*.ppt;*.pptx;*.bmp;*.jpg;*.jpeg;*.gif;*.tif;*.tiff;*.png"

    Now it is working fine but in MAC i m unable to pick excel files, excel files not available in allowed types, all though .xls and .xlsx is been added into filter and working for windows. so what changes required in filter for MAC machine. Thanks Yogesh Agarwal

    A 1 Reply Last reply
    0
    • Y yogesh_kumar_agarwal

      Hi All, i Have made a web application, working fine in WINDOWS and MAC, but in my application i have a file upload option by which, user can select file and upload it on server. For this i use openfiledialog to select files and use filter to filter only allowed file types in selection. the filter is like :

      dlg1.filter=Files Allowed(*.pdf;*.doc;*.docx;*.txt;*.xls;*.xlsx;*.ppt;*.pptx;*.bmp;*.jpg;*.jpeg;*.gif;*.tif;*.tiff;*.png)|*.pdf;*.doc;*.docx;*.txt;*.xls*;*.xlsx;*.ppt;*.pptx;*.bmp;*.jpg;*.jpeg;*.gif;*.tif;*.tiff;*.png"

      Now it is working fine but in MAC i m unable to pick excel files, excel files not available in allowed types, all though .xls and .xlsx is been added into filter and working for windows. so what changes required in filter for MAC machine. Thanks Yogesh Agarwal

      A Offline
      A Offline
      Anurag Gandhi
      wrote on last edited by
      #2

      yogesh_kumar_agarwal wrote:

      docx;*.txt;*.xls*;*.xlsx;*.ppt

      In your filter, its written: *.xls*; I guess, it should be: *.xls;

      Anurag Gandhi.
      http://www.gandhisoft.com
      Life is a computer program and every one is the programmer of his own life.

      A 1 Reply Last reply
      0
      • A Anurag Gandhi

        yogesh_kumar_agarwal wrote:

        docx;*.txt;*.xls*;*.xlsx;*.ppt

        In your filter, its written: *.xls*; I guess, it should be: *.xls;

        Anurag Gandhi.
        http://www.gandhisoft.com
        Life is a computer program and every one is the programmer of his own life.

        A Offline
        A Offline
        Abhijit Jana
        wrote on last edited by
        #3

        Hi Anurag, Have a look into this forum General Indian Topics [^] You may interested over here too :)

        Cheers ! Abhijit Jana | MVP Web Site : abhijitjana.net | Follow Me @ twitter Visit My Blog Abhijit's World of .NET

        A 1 Reply Last reply
        0
        • A Abhijit Jana

          Hi Anurag, Have a look into this forum General Indian Topics [^] You may interested over here too :)

          Cheers ! Abhijit Jana | MVP Web Site : abhijitjana.net | Follow Me @ twitter Visit My Blog Abhijit's World of .NET

          A Offline
          A Offline
          Anurag Gandhi
          wrote on last edited by
          #4

          Cool. :)

          Anurag Gandhi.
          http://www.gandhisoft.com
          Life is a computer program and every one is the programmer of his own life.

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups