wxDatePickerCtrl - Blank Date

If you are using the main C++ distribution of wxWidgets, Feel free to ask any question related to wxWidgets development here. This means questions regarding to C++ and wxWidgets, not compile problems.
Post Reply
tfiler
Earned a small fee
Earned a small fee
Posts: 11
Joined: Wed Jun 29, 2005 9:30 pm

wxDatePickerCtrl - Blank Date

Post by tfiler » Tue Feb 28, 2006 11:49 pm

I am trying to figure out how I can have the wxDatePickerCtrl not show a date if a date hasn't been selected. By default it is showing the current date, but I was hoping to set the control to empty showing the user hasn't selected a date yet. If I set the control to NULL I of course get the error:

(3013): error C2664: 'wxDatePickerCtrl::SetValue' : cannot convert parameter 1 from 'int' to 'const wxDateTime &'

Thanks,
Tod

eco
Filthy Rich wx Solver
Filthy Rich wx Solver
Posts: 203
Joined: Tue Aug 31, 2004 7:06 pm
Location: Behind a can of Mountain Dew
Contact:

Post by eco » Wed Mar 01, 2006 12:32 am

I don't believe there is any way to not show a date, unfortunately. I wanted this appearance when the control was disabled but found no way so I placed the wxDatePickerCtrl in a horizontal box sizer with a wxChoice. I hide one or the other depending on if I want the wxDatePickerCtrl accessible. It doesn't sound like this is what you are looking for, though.

Post Reply