问题已经说得很清楚了 :)
我正在使用MVVM Light在XAML/C#中编写Windows 8应用程序,我注意到EventToCommand功能尚未实现。
有人可以建议任何解决方法吗?
谢谢!
问题已经说得很清楚了 :)
我正在使用MVVM Light在XAML/C#中编写Windows 8应用程序,我注意到EventToCommand功能尚未实现。
有人可以建议任何解决方法吗?
谢谢!
<Slider x:Name="Sl_VolumeSilder">
<Interactivity:Interaction.Behaviors>
<Core:EventTriggerBehavior EventName="ValueChanged">
<Core:InvokeCommandAction Command="{Binding OnSliderValueChangedCommand}" CommandParameter="{Binding ElementName=Sl_VolumeSilder, Path=Value}"/>
</Core:EventTriggerBehavior>
</Interactivity:Interaction.Behaviors>
</Slider>
引用 Interactivity 和 Core 的位置:
xmlns:Interactivity="using:Microsoft.Xaml.Interactivity"
xmlns:Core="using:Microsoft.Xaml.Interactions.Core"
我刚刚在博客中发布了一篇关于这个问题的文章,请查看我的记录。
http://blog.tattoocoder.com/2012/08/getting-started-w-windows-8-mvvm-light.html
使用了@localJoost的WinRTBehaviors和Win8nl。