dateTimePicker控件怎么赋空值
展开全部
初始化时:
this.dateTimePicker1.Format=DateTimePickerFormat.Custom;
his.dateTimePicker1.CustomFormat=" ";事件里写: private void dateTimePicker1_ValueChanged(object sender, System.EventArgs e)
{
this.dateTimePicker1.Format=DateTimePickerFormat.Long;
this.dateTimePicker1.CustomFormat=null; }
已测试
this.dateTimePicker1.Format=DateTimePickerFormat.Custom;
his.dateTimePicker1.CustomFormat=" ";事件里写: private void dateTimePicker1_ValueChanged(object sender, System.EventArgs e)
{
this.dateTimePicker1.Format=DateTimePickerFormat.Long;
this.dateTimePicker1.CustomFormat=null; }
已测试
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询