Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
可能重复: 如何使用 MonthCalender 在文本框中插入日期?
我有textBox1以及MonthCalender1如何将日历中的选定日期映射为字符串textBox1?
textBox1
MonthCalender1
在日历的选定更改事件中尝试此操作:
protected void MonthCalender1 _SelectionChanged(object sender, EventArgs e) { System.DateTime myDate = MonthCalender1 .SelectedDate; textBox1.Text = myDate.ToString ("dd/MM/yyyy"); }