get_open_filename function problem

Discussion in 'Programming' started by Marko03970, Apr 14, 2019.

  1. Marko03970

    Marko03970 Member

    Joined:
    Mar 25, 2017
    Posts:
    4
    Hi everyone!
    I'm making a game and i want to make that players are able to import some files in game.
    Problem is in get_open_filename function because this function can pick only one file.
    Can i make that i can select multiple files in window that is arriving while using get_open_filename function?
     
  2. Binsk

    Binsk Member

    Joined:
    Jun 22, 2016
    Posts:
    505
    Nope, as far as I know. You'll need an extension from the marketplace.

    1) you'll need an extension to make the dialog that allows multiple file selection.

    2) you'll need an extension that allows reading outside the sandbox since you won't be able to use get_open_filename
     
  3. immortalx

    immortalx Member

    Joined:
    Sep 6, 2018
    Posts:
    267
    Samuel Venable likes this.
  4. Samuel Venable

    Samuel Venable Time Killer

    Joined:
    Sep 13, 2016
    Posts:
    1,084
    There is a unique problem with my extension on Windows that I can't seem to figure out. If your files you are selecting are in system root the max files you may select are only 3. so if your files are located for instance "C:\file1.txt" or "I:\file1.txt" Pretty much kills it. but if it's located virtually anywhere else on your machine, whether program files, documents, the desktop, my pictures, etc it should load a lot more than that. If you try to load a specific amount or so more than the dialog can handle from its buffer size the dialog will close abruptly and return an empty string as if you pressed cancel.

    I'm still trying to figure out a fix for these things, and intend to fix them, but right now I'm pretty busy and also stuck on that issue.

    It's not a problem on Mac or Linux fortunately. Just a Windows-only bug with my extension.
     
  5. Marko03970

    Marko03970 Member

    Joined:
    Mar 25, 2017
    Posts:
    4
    Thanks to all of you
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice