[求助]主窗口BeforeClose事件不执行? Post By:2011/10/29 17:16:00 [显示全部帖子]
Dim
sd As WinForm.DateTimePicker Dim ed As WinForm.DateTimePicker sd = e.Form.Controls("StartDate") ed = e.Form.Controls("EndDate") If sd.Value Is Nothing OrElse ed.Value Is Nothing Then MessageBox.Show("请输入起始日期和终止日期!","提示", MessageBoxButtons.OK ,MessageBoxIcon.Information) e.Cancel = True End If