开发者

Root.plist app settings missing when debugging

开发者 https://www.devze.com 2023-01-27 07:15 出处:网络
I have created a settings bundle and Root.plist.When I run my app using the Release|iPhoneSimulator build I can see and edit my settings in the \"Settings app\" just fine, as expected.

I have created a settings bundle and Root.plist. When I run my app using the Release|iPhoneSimulator build I can see and edit my settings in the "Settings app" just fine, as expected.

However when I run my app in Debug|iPhoneSimulation mode my settings are gone and replaced by the Debugger Settings. Is there 开发者_运维技巧a way to keep my original Root.plist settings intack while debugging??

I must be doing something stupid because I can't find any references to anyone else having this problem.

Thanks.


It might be a case sensitivity issue.

MonoDevelop merges the debug settings into your settings files, if it finds a file called Settings.bundle/Root.plist marked as Content in the project, but this check is case sensitive.

If it does not find this file - for example your settings file is cased differently - MD will simply create a new settings file, but the Apple case-insensitive filesystem will consider the filenames to be the same, so it'll end up overwriting yours in the app bundle.


Looks like the examples I've been using to figure out how to do this are bogus.

To resolve the issue I deleted the Root.plist and then re-added it by doing a Add..New File...Property List. Once I added my custom settings to this plist everything started working.

So if you see examples (such as this one, http://conceptdev.blogspot.com/2009/08/monotouch-settingsbundle.html) where they are telling you to manually create an xml file and then rename it to Root.plist, don't do this. It doesn't work.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号