【お知らせ】この部分は英語原文のみでの提供となります。何卒ご了承ください。
2.1.8.34 str_to_date_custom
Contents
Description
Convert a text string that represents date/time into a Julian date value
Syntax
BOOL str_to_date_custom( LPCSTR lpcszDateStr, LPCSTR lpcszFormatStr, double * pDate, DWORD dwOptions = 0 )
Parameters
- lpcszDateStr
- [input] A date/time string
- lpcszFormatStr
- [input] Pointer to a format picture string that is used to form the date string
- pDate
- [output] Pointer will point to Julian date if success else NANUM
- dwOptions
- [input] Optional format options
Return
True if success, else false
Examples
EX1
void str_to_date_custom_ex1() { string strDate = "2003-03-21"; string strFormt = "yyyy'-'MM'-'dd"; double db; if(str_to_date_custom(strDate, strFormt,&db)) { printf("You have entered %s\n", get_date_str(db)); } }
Remark
See Also
Header to Include
origin.h