0
我有功能滑塊:Button.Click事件
private void slider_change(object sender, RoutedPropertyChangedEventArgs<double> e)
{
if (e.NewValue < 2)
{
this.button1.Content = "A";
this.button1.Click += aa;
}
if (e.NewValue < 6 && e.NewValue > 4)
{
this.button1.Content = "B";
this.button1.Click += bb;
}
if (e.NewValue < 10 && e.NewValue > 8)
{
this.button1.Content = "C";
this.button1.Click += cc;
}
if (e.NewValue < 4 && e.NewValue > 2)
{
this.button1.Content = "D";
this.button1.Click += dd;
}
if (e.NewValue < 8 && e.NewValue > 6)
{
this.button1.Content = "E";
this.button1.Click += ee;
}
}
所以,我有一個按鈕,它5種不同的功能。如何刪除button1.click的以前處理程序?