当前位置: 代码迷 >> Silverlight >> <EventTrigger RoutedEvent="Rectangle.Loaded">这个有关问题
  详细解决方案

<EventTrigger RoutedEvent="Rectangle.Loaded">这个有关问题

热度:8370   发布时间:2013-02-26 00:00:00.0
<EventTrigger RoutedEvent="Rectangle.Loaded">这个问题

<Grid.Triggers>
            <EventTrigger RoutedEvent="Grid.Loaded">
                <BeginStoryboard>
                    <Storyboard>
                        <ColorAnimation To="Red" Duration="00:00:01" Storyboard.TargetName="LayoutRoot" Storyboard.TargetProperty="Background"></ColorAnimation>
                    </Storyboard>
                </BeginStoryboard>
            </EventTrigger>
        </Grid.Triggers>


上面代码中界面加载完毕就执行动画了,RoutedEvent貌似不支持其他事件额,要是我想点击的时候才执行动画用上面那种方式要怎么做?
------解决方案--------------------------------------------------------
type.eventName

RoutedEvent 类
  相关解决方案