When i launch the Application from XCode, the current working directory is set to the Proper Path by Juce , but when i launch the Same from Finder, It goes to the Default path /Volumes/Macintosh HD/…
Sorry, I may be wrong in my Explanation …
Here is my Issue …
When we launch a executable in Windows, File::getCurrentWorkingDirectory().getFullPathName() gets resolved to the path from where that exe is Launched .
But in MAC, if i launch the executable from Finder, File::getCurrentWorkingDirectory().getFullPathName() gets resolved to the default root directory (say /MacintoshHD) … It gets Resolved to a proper directory only when the Application is run via a Debugger (XCode) … Do i need to do any setting in some Info.plist file or some thing to make it resolve to a proper Path ?
I have tried ur Suggestion using File::getSpecialLocation() for MAC and it works …
I am Just comparing Windows and MAC here . In Windows, File::getCurrentWorkingDir() is the folder that contains my APP … But in MAC it is not like that …
U mean to Say, for Windows we use File::getCurrentWorkingDir() but for MAC, the same thing doesnt work and we have to use File::getSpecialLocation() …
The CWD is irrelevant in a GUI app, it’s really only meaningful in the context of parsing filenames in a command-line app. But it’s a pretty fundamental computing concept and you should understand what it means.