The error :
AttributeError: 'DateTime' object has no attribute 'isoformat' - I'm
trying to insert this into a MySQL database using MySQLdb so the ISO
format is kinda important!
Is the wx.DateTime not the same as a normal python datetime? Can
anyone tell me what I've got wrong?
Python 2.6 on Win32 (XP) and wxPython 2.8.10.1
The error :
AttributeError: 'DateTime' object has no attribute 'isoformat' - I'm
trying to insert this into a MySQL database using MySQLdb so the ISO
format is kinda important!
Is the wx.DateTime not the same as a normal python datetime? Can
anyone tell me what I've got wrong?
No, they are not the same they are two completely different classes.
Though they have the same purpose.
One thing I'm stumped on, is getting time. wx doesn't seem to have
the same sort of chooser for time as it has for dates, I've found the
masked.timectrl() widget, but it returns a string of the format
HH:MM:SS (AM|PM) which isn't a format that MySQL can use as a time.
I'm trying to get user input to choose a date and a time from a form,
defaulting to now. wx.DatePickerCtrl() doesn't seem to present a time
option (although it returns DateTime but with a time of 00:00:00),
which would probably be the ideal if it did. Any suggestions for the
best widget to use for this?
Thanks again!
Carl
···
On May 29, 2:16 am, Cody Precord <codyprec...@gmail.com> wrote: