0
命名空間SilverlightApplication1 { 公共部分類的MainPage:用戶控件 { 公共的MainPage() { 的InitializeComponent();的Silverlight&事件
datePicker1.SelectedDateChanged -= datePicker1_SelectedDateChanged;
datePicker1.SelectedDate = DateTime.Today;
datePicker1.SelectedDateChanged += datePicker1_SelectedDateChanged;
}
private void datePicker1_SelectedDateChanged(object sender, SelectionChangedEventArgs e)
{
MessageBox.Show("datePicker1_SelectedDateChanged");
}
}
}
爲什麼會出現消息框?