If my application's bundle identifier is net.jim.HelloApp, then the path to its sandbox library folder is
/Users/me/Library/Containers/net.jim.HelloApp/Data/Library
, where me is the current user. I can get that path with
FileManager.SearchPathDirectory.libraryDirectoryI wonder if there is a quick way of getting the path to its plist file in the preference folder? Its path should be
/Users/me/Library/Containers/net.jim.HelloApp/Data/Library/Preferences/net.jim.HelloApp.plist
It seems that the application will try to access this file when the user resizes application window. The thing is that my application doesn't even have the restorable switch on. If this file doesn't exist, then the application can crash.