EVT_CUSTOM function type errors...

Mark Williams (MWP) mwp at internode.on.net
Thu Sep 6 08:15:09 PDT 2007


Thanks, that was a typing error in the email (i didnt copy & paste).
The actualy code does have the ::, so thats not the problem.

So, any other ideas?

> MyApp:OnThreadEnd should be MyApp::OnThreadEnd (that's why I hate defines ...)
> 
> there might be other errors also, though ...
> 
> ----- Original Message ----
> From: Mark Williams (MWP) <mwp at internode.on.net>
> To: wx-users at lists.wxwindows.org
> Sent: Wednesday, September 5, 2007 8:07:59 PM
> Subject: EVT_CUSTOM function type errors...
> 
> Hi all,
> 
> I have:
> 
> class MyApp: public wxApp
> {
>     ......
>     void OnThreadEnd(wxCommandEvent &event);
> }
> 
> BEGIN_EVENT_TABLE(MyApp, wxApp)
>     EVT_CUSTOM( myEVT_THREAD_END, wxID_ANY, MyApp:OnThreadEnd)
> END_EVENT_TABLE()
> 
> void MyApp::OnThreadEnd(wxCommandEvent &event)
> {
>     ....
> }
> 
> On compiling under MSVS-2005, i get the error:
> cannot convert from 'void (__thiscall MyApp::*)(wxCommandEvent &)' to 'wxEventFunction'
> 
> Whats wrong with this??
> 
> Thanks in advance.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: wx-users-unsubscribe at lists.wxwidgets.org
> For additional commands, e-mail: wx-users-help at lists.wxwidgets.org
> 
> 
> 
> 
> 
> 
> 
> 
>        
> ____________________________________________________________________________________
> Sick sense of humor? Visit Yahoo! TV's 
> Comedy with an Edge to see what's on, when. 
> http://tv.yahoo.com/collections/222




More information about the wx-users mailing list