|
|
On 20/11/2014 20:48, Leroy wrote:
> I'm having some trouble.
> I'm trying to have POV write datetime to a file in the form:
>
> // Made Wednesday 11-19-2014 07:33 PM
>
> Everything is fine except the hour: it was 1:33 PM
>
> Here what I wrote:
> #write(Mfile,"// Made ",datetime(now,"%A %m-%d-%Y %I:%M %p"),"\n")
>
> The (%I) above, I got from my C++ book and don't have a C book.
> I don't think there can be much different between them.
> Is there something I missing, or is this a POV 3.7 bug?
datetime is from boost.
Your date format is not correct. '-' is for iso 8601, american's date
should use '/'. Iso 8601 is YEAR-Month-Day (the '-' might be omitted in
non-extended format)
There is only one format for date, Iso 8601. All other formats are doomed.
The difference of 6 hours might be due to your timezone (which you did
not print, or its settings somewhere): give a try to "%z", "%Z" or "%ZP"
--
IQ of crossposters with FU: 100 / (number of groups)
IQ of crossposters without FU: 100 / (1 + number of groups)
IQ of multiposters: 100 / ( (number of groups) * (number of groups))
Post a reply to this message
|
|