0

I have a string wchar_t which contains the value 2015-06-01-00.00.00 or YYYY-MM-DD-HH.MM.SS format. I need to convert this to the timestamp which can be represented in the long variable.

I cannot use 3rd party libraries like boost or any other which I have to add a dependency of.

Please help me out with this situation.

LPTSTR lStr = _TEXT("2015-06-01-00.00.00");
long timestamp = convertToTimeStamp(lStr);

I need a function like convertToTimeStamp.

Faraj Farook
  • 14,385
  • 16
  • 71
  • 97

0 Answers0