简体   繁体   English

绑定到IsolatedStorageSettings

[英]Binding to IsolatedStorageSettings

Binding={Binding Source={x:Static ...}}

doesn't seem to work, so my static wrapper class doesn't work. 似乎不起作用,因此我的静态包装器类不起作用。

How can we make a two-way binding to a key in WP7 IsolatedStorageSettings ? 如何在WP7 IsolatedStorageSettings对密钥进行双向绑定?

If anyone is wondering, I built a non-static class, which had non-static properties that were simply aliases for the static properties. 如果有人想知道,我构建了一个非静态类,该类具有非静态属性,这些属性只是静态属性的别名。 I then made an instance of it, and added it as a resource to App.xaml, then bound against that resource. 然后,我为其创建了一个实例,并将其作为资源添加到App.xaml,然后与该资源绑定。 This also allows you to add properties like VisibleIfTrial etc. 这也允许您添加诸如VisibleIfTrial等属性。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM