Dear all
I am using below this code for getting Date with Time Value when I will enter data through Date Time Picker and Masked Edit Control. I am getting error like "string was not recognized as a valid date time".
string SCDateTimeValue = Convert.ToDateTime(dtpSCDate.Value) + mskSCTime.Text;
Thanks all
How to calculate date time using dtpicker and masked edit
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.

Hemant SrivastavaRank #581 · 4.2K reputationPosted Jan 30, 2014, 5:14 AM EST
you should convert dtpSCDate.Value to string format.
PRASANTA BISWAS26 reputationPosted Jan 30, 2014, 6:22 PM EST
string SCDateTimeValue = Convert.ToString(dtpSCDate.Value) + mskSCTime.Text;
Output like "1/10/2014 12:00:00 AM06:58" But I want like "1/10/2014 06:58 AM" It's still not coming.
Hemant SrivastavaRank #581 · 4.2K reputationPosted Jan 31, 2014, 11:41 AM EST
string SCDateTimeValue = dtpSCDate.Value.ToShortDateString() + mskSCTime.Text;