|
감사합니다.
StrToDateTime 을 써 본결과 ...
DateTimeToStr 으로 문자열로 변환 --> 이를 가지고 다시 StrToDateTime 을 취해서 time 을 구하려 하면
에러가 발생합니다.
문자열로 변환시 2005-1-1 오전 7:00:00 이 나오는데... StrToDateTime 은 이 오전이라는 글자에서
에러를 나타내더군요...
찾아 보니 영문은 되는 거 같은데... DateTimeToStr 형태가 영문 형태로 변환되게 할 수는 없나요?
시간을 더하고 빼고 해야 되서 글자와 함께 왔다갔다 해야 되서..
민병권 님이 쓰신 글 :
: StrToDateTime(const AnsiString S) 라는 함수가 있네요.
: 근데, S에 잘못된 date/time format이 지정되면 EConvertError 에러를 뱉어 낸다고 되어 있네요.
: 도움말을 참고하세요.
:
: 아래는 도움말 원문입니다.
:
: Converts an AnsiString object to a TDateTime object.
:
: extern PACKAGE System::TDateTime __fastcall StrToDateTime(const AnsiString S);
:
: Description
:
: Call StrToDateTime to parse a string that specifies a date and time value. If S does not contain a valid date, StrToDateTime throws an EConvertError exception.
:
: The S parameter must use the current locale뭩 date/time format. In the US, this is commonly MM/DD/YY HH:MM:SS format. Specifying AM or PM as part of the time is optional, as are the seconds. Use 24-hour time (7:45 PM is entered as 19:45, for example) if AM or PM is not specified.
:
: Y2K issue: The conversion of two-digit year values is determined by the TwoDigitYearCenturyWindow variable. For more information, see StrToDate.
:
: Note: The format of the date and time string varies when the values of date/time formatting variables are changed.
|