-
dataTimePickerC#/WindowForm 2022. 4. 6. 11:23
디자인 글씨체는 메이플스토리로 사용함
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace wdq { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void DateTimePicker1_ValueChanged(object sender, EventArgs e) { DateTime today = DateTime.Today; DateTime sDay = dateTimePicker1.Value; textBox1.Text = today.Subtract(sDay).TotalDays.ToString("0"); } } }
실행코드
실행결과 'C# > WindowForm' 카테고리의 다른 글
C# Chart그리기-1 (0) 2022.06.01 ACCESS를 사용한 DB연결 -3 (PhoneBook) (0) 2022.05.18 Timer 사용 (0) 2022.04.06 ComboBox를 사용한 학점 계산기 (0) 2022.04.06 ListBox (0) 2022.04.06