0
请告诉我如何解决我的问题。情况如下: 我有一个列表框里面的图像,我想要一些图像闪烁,有些不是。我有财产“Emergeny”,如果这是真的图像应该眨眼,现在的问题是我怎么能绑定它。我尝试绑定到“Duartion”或“To”属性,但我收到一个错误。下面的代码是我闪烁的图像。如何绑定DoubleAnimation Enabled/Disabled
<Image Height="32" Width="32" Source="{Binding Emergency, Converter={StaticResource boolToPath}}">
<Image.Style>
<Style>
<Style.Triggers>
<EventTrigger RoutedEvent="Image.Loaded">
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetProperty="(Image.Opacity)" BeginTime="0:0:0" Duration="0:0:0.5"
From="1.0" To="0.0" RepeatBehavior="Forever" AutoReverse="True" />
</Storyboard>
</BeginStoryboard>
</EventTrigger>
</Style.Triggers>
</Style>
</Image.Style>
</Image>
感谢,那还可以帮助[链接] http://msdn.microsoft.com/en-us/library/ms742536的.aspx – Tiho 2011-03-14 13:42:28