Question calendar control

elic05

Member
Joined
Nov 2, 2008
Messages
19
Programming Experience
Beginner
I want to fill a textBox with a date from a calendar control
the problem is when the user selects a date the textBox is filled not only with the date but also with the time
like so
20/10/2008 00:00:00

can i get only the time from this control?
 
Instead of using the ToString method for the Date value as you are doing now (probably implicitly), use for example the ToShortDateString method.

The Date data type is represented by the DateTime structure, take some time to read through its member list in help. There are many useful members, also several that can be used in your case, including a ToString method where you can specify a custom string format.
 
Back
Top