B4J Question Mac file/folder paths - [HELP REQUEST]

Discussion in 'B4J Questions' started by aidymp, Mar 6, 2015.

  1. aidymp

    aidymp Active Member Licensed User

    Hi, I wrote my App for Android in B4A, And have now made it using B4J, It works as expected on Windows, I am itching to get it working on Apple Mac (But I dont have one) I have 2 VMWare Mac machines that boot and work on my PC fine (But Java will not work) The JAR either refuses to run, or Runs but displays blank Windows...

    The Problem i have is that I only have to detect the OS (DONE) and change the paths of the XBMC/KODI directories if its a Mac and the App should work exactly as the same as the Windows version! The problem is I don't just want to add the paths and say it now works on Mac!

    The Path to say the userdata folder on a Mac according to KODI is

    "/Users/<your_user_name>/Library/Application Support/Kodi/userdata/"

    So would the command

    XBMCPath= JO.RunMethod("getProperty",Array As Object("user.home"))&"/Library/Application Support/Kodi/userdata
    Point to the correct place on a Mac?

    My App - for Android And As a Windows .exe are here http://aidymatic.co.uk

    Any tips or pointers are welcome.


  2. Erel

    Erel Administrator Staff Member Licensed User

    GetSystemProperty("user.home", "") returns /Users/<user name>. Your code should work (though you can replace jo.RunMethod with GetSystemProperty keyword).
  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