通用 Windows 应用程序中具有绑定的 Style.Setter [英] Style.Setter with Binding in Universal Windows Applications

查看:26
本文介绍了通用 Windows 应用程序中具有绑定的 Style.Setter的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如下面的问题所述,Setter 在 Windows RT/Phone 8.1 中不能包含绑定

=> 绑定 SelectedItemsListView 到 Windows Phone 8.1 中的 ViewModel

这在新的通用 Windows 应用程序中是否有所改变?

Has this changed in the new Universal Windows Applications?

仍然没有绑定值吗?

推荐答案

好的,你不能使用正常的方式绑定到 DataContext,但是你可以使用其他(智能)方法来做到:

OK, you can't bind to the DataContext using the normal ways, but you can do it using other (smart) methods:

请看这个.它提供了一个帮助器",允许使用 Setter 绑定到 DataContext.

Please, look at this. It provides a "helper" that allows to bind to the DataContext with a Setter.

http://dlaa.me/blog/post/10089023

这篇关于通用 Windows 应用程序中具有绑定的 Style.Setter的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆