1 Reply Latest reply on Jan 9, 2015 2:49 AM by Marc Autret

    Mac<->Win path traps - looking for help

    Jump_Over Level 5

      Hi everyone,


      I am hoping someone with Mac will advice me how to manage the problem...


      I am pushing file paths to the array from different sources (UI, doc links,  external list etc). The goal is to manage this on both Mac and Windows platform.

      Unfortunately, I can not test using MacOS (lack of hardware nearby). The problem is to proper encoding for "special characters" alike "slash", "backslash", "question mark" etc - which - as far as I know - are acceptable while naming files/folders in Mac OS.


      Lets say File is some real file on Mac. I stored File.fsName to var mPath and tried to eval back to the File from this var later on --> File(mPath) leads me to "undefined" path cause i.e slash (or backslash - I am not sure) is replaced 'on the fly' by colon.


      Is a solution to use File.absoluteURI to store a proper encoding in this case or is it much more complex issue?

      Could someone with any experience advice me which way to go?