我想在鼠標懸停時更改圖像的位置。我有:更改WPF中的圖像位置
<Image
Name="cat"
Source="CatRun.bmp"
Visibility="Hidden"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Width="100"
Height="100"
UIElement.MouseEnter="cat_MouseEnter"/>
在XAML和:
private void cat_MouseEnter(object sender, MouseEventArgs e)
{
}
在C#
。
如何在畫布上專門設置位置?
VAR =圖像(圖像)發送者; Canvas.SetLeft(image,42); – 2012-02-17 22:49:00