Questions
heshaniheshaniasked 4 months ago
How to get only the date value from a Windows Forms DateTimePicker control?
1

1 Answers

Accepted
codegenlabcodegenlabanswered 4 months ago
You may try following code.
string theDate = dateTimePicker1.Value.ToShortDateString();
or, if you would like to specify the format of the date:
string theDate = dateTimePicker1.Value.ToString("yyyy-MM-dd");
1