datetimepicker value
how we delete the time from datetimepicker control? plz help.
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
ArshadPosted Apr 11, 2011, 8:51 AM
you will have the InitializeComponent() method, there your control will get initialize, just put the below line while initializing the datetimepicker control
this.dateTimePicker.CustomFormat = "dd.MM.yyyy";
this.dateTimePicker.Format = System.Windows.Forms.DateTimePickerFormat.Custom;
this.dateTimePicker.Location = new System.Drawing.Point(15, 55);
this.dateTimePicker.Name = "dateTimePicker";
this.dateTimePicker.Size = new System.Drawing.Size(249, 22);
this.dateTimePicker.TabIndex = 0;
just follow the above two highlighted line.
Regards,
Arshad