WPF VB.NET 代码实现界面动画效果

2021-03-09 07:30

阅读:940

标签:实现   rom   media   path   get   double   out   ase   ati   

WPF VB.NET 代码实现界面动画效果

 

Imports System.Windows.Media.Animation

 

例子:

Dim result As New Storyboard
Dim animation As New DoubleAnimation With {
  .From = 300,  起始数值
  .EasingFunction = New PowerEase() With {.EasingMode = EasingMode.EaseInOut, .Power = 3},
  .To = 0,  结束数值
  .Duration = New Duration(TimeSpan.FromSeconds(0.5))  持续时间
  }
Storyboard.SetTarget(animation, 控件名)
Storyboard.SetTargetProperty(animation, New PropertyPath("属性"))
result.Children.Add(animation)
result.Begin()

 

WPF VB.NET 代码实现界面动画效果

标签:实现   rom   media   path   get   double   out   ase   ati   

原文地址:https://www.cnblogs.com/dirror/p/12759477.html


评论


亲,登录后才可以留言!