Search Unity

File Browser - Native file browser for standalone

Discussion in 'Assets and Asset Store' started by Stefan-Laubenberger, Dec 28, 2017.

  1. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    It's still in the review process, but it should be available in the next few days.


    Edit:
    FB PRO is in the store!
     
    Last edited: Apr 18, 2019
    AlanMattano likes this.
  2. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've just released version 2019.1.2 of File Browser.
    Main changes:
    • Editor integration added
    • Set API level for Unity 2018+ fixed
    • Minor code improvements
    • Documentation improved

    The Editor integration looks like this:
    Editor-Configuration.PNG
    Editor-Help.PNG
    Editor-About.PNG

    Enjoy!
     
    AlanMattano likes this.
  3. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    What is your current version of FB? If you use 2019.1.2 you shouldn't set the API level manually - we added a script that should take care of that... Which is your Unity version?

    About the build warning: this is harmless and the build will complete successfully and there is no impact on the application.
    What bothers me is your second problem - I tried it on my side but everything works, even when I open the save panel like this:
    Code (CSharp):
    1. string path = FileBrowser.SaveFile(null, null, null, "");
    How do you "provoke" the error?


    Cheers
    Stefan
     
  4. andyz

    andyz

    Joined:
    Jan 5, 2010
    Posts:
    1,101
    Sorry Stefan, getting my file browsers mixed up. Perhaps I should use yours - "Native File Browser" is the one with issues! It's confusing because the API is named the same in both
     
    Stefan-Laubenberger likes this.
  5. AlanMattano

    AlanMattano

    Joined:
    Aug 22, 2013
    Posts:
    1,044
    The link is not ready in the browser.
    But if you open Unity and go to AssetStore window, search for File Browser Pro and is there.

    Stefan, the update window pops up but I was updating Unity and I press not now. Now I'm ready to update your asset to the latest vr. I wish to use your update button but I do not find it anywhere. Maby to include it in About section if you have not done it yet?
     
  6. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi Alan

    The link should work, isn't it?

    Since 2019.2.1 there is a new Editor integration with an "About"-tab. There should be everything you are looking for:
    upload_2019-2-1_10-6-17.png

    I hope this is what you meant.


    Cheers
    Stefan
     
    AlanMattano likes this.
  7. AlanMattano

    AlanMattano

    Joined:
    Aug 22, 2013
    Posts:
    1,044
    YES, perfect!

    Was hard for me to update from 2019.1.1 to 2019.1.2 probably because, before importing the asset, I use to delete FileBroser folder. And my script pointing using Crosstales.FB; triggering errors that probably block the import process. FileBrowser.unitypackage did not unpack automatically. I was able to unpack it manually, importing it as a custom package.

    Now that there is this [Upgrade] button, it will be faster since the Unity asset store is very slow these days. Thanks a lot for this tool!
     
    Last edited: Feb 1, 2019
    Stefan-Laubenberger likes this.
  8. jd_terry

    jd_terry

    Joined:
    Sep 20, 2018
    Posts:
    1
    Hi
    If you open the FileBrowser using OpenSingleFile (when the FB is open), Unity will stop and Unity will run after you close the FileBrowser dialog box. Is there a way to keep Unity running even when FileBrowser is running?
     
  9. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi jd_terry

    Unfortunately, this is currently not possible - Unity has to wait until the file dialog is closed because it's a modal dialog.
    We're trying to find a solution but I can't promise anything.

    Cheers
    Stefan
     
    Last edited: Feb 25, 2019
  10. StarCoop

    StarCoop

    Joined:
    Nov 26, 2016
    Posts:
    16
    Hi there,

    I just noticed that multiselect is not possible in Editor! Can you explain why that is and if this is about to change in the future? It's hard to debug when you need to create the standalone everythim ^^.

    Edit: Nevermind, damn it, I just saw it - EditorUtilities. Any idea to work around that?
    Edit2: OK, so basically I just removed the defines for the FileBrowserWindows class and assigned a the Windows platform wrapper in the FileBrowser.cs.
    I assume the reason for this was to keep the Editor functionality independent of the actual platform. But, as the Editor version doesn't support multiselect, I would only check for the platform and not make a different wrapper when running in Editor.
     
    Last edited: Mar 8, 2019
  11. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    We made a new checkbox in the "Configuration" that solves the issue you mentioned:
    upload_2019-3-8_14-25-57.png

    If you want to have access to the new version, please send us an email.


    So long,
    Stefan
     
  12. davidrmsg

    davidrmsg

    Joined:
    Dec 25, 2017
    Posts:
    1
    Hi,
    Any support for il2cpp yet? I'm getting crashes when using il2cpp on Windows.

    Also I'm getting the following warning in the editor:
    System.Windows.Forms.dll assembly is referenced by user code, but is not supported on StandaloneWindows64 platform. Various failures might follow.

    It seems that FileBrowserWindows.cs references System.Windows.Forms.

    Thanks
     
  13. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    We're working on a solution for IL2CPP under Windows, but it's not supported with the actual version.

    Stay tuned!


    Cheers
    Stefan


    Edit:
    The PRO supports IL2CPP under Windows
     
    Last edited: Apr 18, 2019
  14. AlanMattano

    AlanMattano

    Joined:
    Aug 22, 2013
    Posts:
    1,044
    What does it mean Windows: "System.Windows.Forms.dll" removed for us as users?
    There are things we can't do any more?
    Did you convert that to C#?
    I'm a regular Windows user saving and loading files .txt or my own format extension
     
  15. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi Alan

    Nothing changes for you as a user. We just removed the dll from the package since it's no longer used.
    This also saves space (the dll was around 2MB).


    Cheers
    Stefan
     
    AlanMattano likes this.
  16. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    12
    I need a file enumeration method for the code I'm writing, targeting UWP in Mixed Reality. I thought of using FileBrowser Pro to at least enumerate the files and then build a user interface (since the current FileBrowser interface does not work in Mixed Reality).

    So I'm testing my approach in normal Windows, not UWP, with the FileBrowser free, and with :

    string[] filenames;
    filenames = FileBrowser.GetFiles("s:\\deretour", false,"mp4")

    There are a dozen of files in the directory, but it returns nothing…. anything I'm doing wrong? Or maybe I'm assuming wrongly that this would work?

    Code snippets and examples would be useful in the documentation.

    Thanks!

    FG
     
  17. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    You have to add an end-delimiter to the path, like "s:\\deretour\".


    Cheers
    Stefan
     
  18. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've just released version 2019.3.0 (and 2019.2.3 for the free version).
    Changes:
    • Windows:
      • support for IL2CPP! (PRO only)
      • automatically add the extension for save files
    • Updated to Common 2019.2.5
     
    Last edited: Apr 18, 2019
  19. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    The new versions are in the store!
     
    AlanMattano likes this.
  20. Gloryiam

    Gloryiam

    Joined:
    Oct 25, 2017
    Posts:
    6
    Hi Stefan,

    Thank you for this very useful plugin!

    I have been using it for a couple weeks now and it has been great until the last update (free version 2019.2.3). After upgrading, I can launch my native file browser in the editor just fine but it does not work in my standalone build anymore. I have not changed any code in my project since before the update. Do you know what could be causing this?

    Edit: My build is for Windows 10

    Thank you!
    Jacob
     
    Last edited: Apr 9, 2019
  21. Vic070

    Vic070

    Joined:
    Aug 6, 2016
    Posts:
    3
    Same is happening to me. I'm using Unity 2018.3.9f1.
     
  22. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi Jacob

    Thank you for your report! We will investigate this.


    So long,
    Stefan
     
  23. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Please give us time to find the issue.

    Btw, I know it sounds a bit cheap, but the PRO version works 100%. ;) We implemented a new way to support IL2CPP and it's extensively tested.
     
  24. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've found the build problem under Windows and released version 2019.2.4.

    @Gloryiam @Vic070
     
    Last edited: Apr 11, 2019
  25. Gloryiam

    Gloryiam

    Joined:
    Oct 25, 2017
    Posts:
    6
    Stefan-Laubenberger likes this.
  26. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Thank you very much!
     
  27. Vic070

    Vic070

    Joined:
    Aug 6, 2016
    Posts:
    3
    Stefan-Laubenberger likes this.
  28. raymondtsang_amvr

    raymondtsang_amvr

    Joined:
    Feb 26, 2019
    Posts:
    1
    Using 2018.3.6f1, build with demo scene 'ExampleSync'
    Cannot show the open dialog when clicking the button
    It works in Unity Editor
     
  29. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    AlanMattano likes this.
  30. GladFoxx

    GladFoxx

    Joined:
    May 16, 2017
    Posts:
    3
    NullReferenceException: Object reference not set to an instance of an object
    UnityEditor.GameObjectInspector.ClearPreviewCache () (at C:/buildslave/unity/build/Editor/Mono/Inspector/GameObjectInspector.cs:201)
    UnityEditor.GameObjectInspector.OnDisable () (at C:/buildslave/unity/build/Editor/Mono/Inspector/GameObjectInspector.cs:189)
    UnityEditor.AssetDatabase:ImportPackage(String, Boolean)
    Crosstales.FB.EditorTask.ZInstaller:.cctor() (at Assets/Plugins/crosstales/FileBrowser/Editor/Task/ZInstaller.cs:25)
    UnityEditor.EditorAssemblies:processInitializeOnLoadAttributes()
     
  31. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    We never saw this exception before... :( Which Unity version are you using?
    However, please try to restart Unity. If this doesn't help, please delete "ZInstaller" and import the "FileBrowser.unitypackage" manually.


    Cheers
    Stefan
     
  32. amidofu

    amidofu

    Joined:
    Mar 1, 2016
    Posts:
    11
    Does "directory" argument in FileBrowser.OpenSingleFile work?
    I tried to pass directory like "E:/UnityProjects" but it always use the folder where I opened a file successfully last time as the root folder for the File Open Dialog.

    File Browser version: 2019.2.4
    Unity version: 2017.4.12
    OS: Windows 10 64 bit
     
  33. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    Yes, we just saw this is a bug - thank you for reporting this!
    We will release a fix today.

    If you need the fix right now, send me an email.


    Cheers
    Stefan
     
    amidofu likes this.
  34. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've just released version 2019.3.3 (and 2019.2.5 for the free version).

    Main change is for Windows: OpenFile and SaveFile are now working correctly with paths
     
  35. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    The new versions are in the store!
     
  36. frangagn

    frangagn

    Joined:
    Sep 20, 2018
    Posts:
    12
    I just purchased FileBrowser Pro, the paid version, because I'm developing in UWP for Mixed Reality, and I'm having lots of problems with it.

    The first thing is that I need to get the directories from the root of a drive, for example S:/ or G:/ using:

    FileBrowser.GetDirectories("D:/Downloads/", true);

    or

    FileBrowser.GetDirectories("D:/Downloads/", false);


    When I do this, I get:

    Could not scan the path for directories: System.ArgumentNullException: Value cannot be null.
    Parameter name: path
    at System.IO.Directory.GetDirectories (System.String path, System.String searchPattern, System.IO.SearchOption searchOption) [0x00003] in <d7ac571ca2d04b2f981d0d886fa067cf>:0
    at Crosstales.Common.Util.BaseHelper.GetDirectories (System.String path, System.Boolean isRecursive) [0x00009] in C:\Users\fran_\Documents\test Filebrowser alone\Assets\Plugins\crosstales\Common\Scripts\Util\BaseHelper.cs:568
    UnityEngine.Debug:LogWarning(Object)
    Crosstales.Common.Util.BaseHelper:GetDirectories(String, Boolean) (at Assets/Plugins/crosstales/Common/Scripts/Util/BaseHelper.cs:572)
    Crosstales.FB.FileBrowser:GetDirectories(String, Boolean) (at Assets/Plugins/crosstales/FileBrowser/Scripts/FileBrowser.cs:358)
    fbtest:OpenSingleFile() (at Assets/fbtest.cs:35)
    fbtest:Awake() (at Assets/fbtest.cs:15)

    but if I specify the file path, such as "D:/downloads/" I get the list of directories within. So how can I get a list of logical drives, let alone get the directories from the root of that drive?

    Then, let's say I specify a directory like S:/deretour/ as you suggested above, using for example:

    string[] path = FileBrowser.GetFiles( "S:/deretour/", true,"*");

    I get the list of files or directories. However, when I try to BUILD it, I get multiple errors:
    "Assets\Plugins\crosstales\FileBrowser\Scripts\Wrapper\FileBrowserWSA.cs(66,13): error CS0200: Property or indexer 'FileBrowserWSAImpl.isBusy' cannot be assigned to -- it is read only"
    "Assets\Plugins\crosstales\FileBrowser\Scripts\Wrapper\FileBrowserWSA.cs(88,13): error CS0200: Property or indexer 'FileBrowserWSAImpl.isBusy' cannot be assigned to -- it is read only"
    "Assets\Plugins\crosstales\FileBrowser\Scripts\Wrapper\FileBrowserWSA.cs(107,13): error CS0200: Property or indexer 'FileBrowserWSAImpl.isBusy' cannot be assigned to -- it is read only"

    I'm really frustrated.... I purchased the pro version because I wanted to use it with UWP, let alone working VR, as it claims to be compatible, but how do I do this??? The documentation is very unclear about this. It does not even work in a blank application set to UWP with the code above. I've read the documentation inside out to try to find answers to this, to no avail.

    Where/how could I get help?
     
  37. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    I wrote you an email.
     
  38. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've just released version 2019.3.4 of File Browser PRO.
    Main changes:
    • Windows: native integration added
    • "GetFiles" and "GetDirectories" improved and support for UWP added
    • UWP bug resolved
    • Updated to Common 2019.3.1
     
  39. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    The new version is in the store!
     
  40. wl919863201

    wl919863201

    Joined:
    Oct 8, 2018
    Posts:
    3
    Hello, stefan. First of all, thank you so much for creating it.

    It works fine on Windows, but I wanted to run my program on Linux, and I had a little problem, I used your "EaxpleScene" build and run on Linux, and when I click on any button about the file browser, my program will not respond, I checked the log, and unfortunately there is no information about this problem.

    This problem may not be caused by your work, because I also have this problem with another file browser on github, but I know little about Linux, so I would like to ask for your help.

    Thank you for any help.

    I'm sorry my English is poor.
     
  41. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    Please replace under "Assets/Plugins/crosstales/FileBrowser/Native/Linux" the file "libStandaloneFileBrowser.so" with the attached file and let me know if it helps.
    Btw, GTK 2+ must be installed.


    So long,
    Stefan
     

    Attached Files:

  42. AlanMattano

    AlanMattano

    Joined:
    Aug 22, 2013
    Posts:
    1,044
    Feedback idea for all your software:
    We can read a release note and how to update after pressing the "Update" button and before the Download button.

    upload_2019-5-18_10-18-11.png
     
  43. AlanMattano

    AlanMattano

    Joined:
    Aug 22, 2013
    Posts:
    1,044
    How do I correctly update from 2019.2.5 to 2019.2.6?
     
  44. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We will consider adding this feature in the future :)
     
    AlanMattano likes this.
  45. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
  46. wl919863201

    wl919863201

    Joined:
    Oct 8, 2018
    Posts:
    3
    Thank you for your reply.I did this,but it didn't work.:(By the way, do I need to release it with Unity3D for Linux?
    Or can you tell me your Linux system information?
    This is my system information:
    Ubuntu 18.04.2 LTS
    Operating system type:64
    GNOME:3.28.2
    And GTK2+ is installed.
     
    Last edited: May 20, 2019
  47. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    Hi

    Please send me an email to help you further.
    Thank you!


    Cheers
    Stefan
     
  48. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    We've just released version 2019.3.5 (and 2019.2.7) of FB.
    Main changes:
    • Windows: native integration for Unity 2019+ improved
    • Linux: GTK2+ version added (see "GTK2.zip")
    • Updated to Common 2019.3.2
     
    AlanMattano likes this.
  49. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    1,250
    The new versions are in the store.
     
  50. eggtart

    eggtart

    Joined:
    Feb 4, 2013
    Posts:
    23
    Is it true that if I am using Mac, I will not be able to use OpenSingleFile() inside the Editor? Thanks!