You need to post more code so we can see what is wrong
a) The place where the event is loaded from what is the context there ?
Constructor ? Open Event? Init Event ? what ?
b) The REAL definition of the class or control.
Björn
----- Original Message -----
From: "Darren Boon" <dboon at renlearn dot ca>
To: "'REALbasic Plugins'" <realbasic-plugins at lists dot realsoftware dot com>
Sent: Thursday, July 21, 2005 4:02 PM
Subject: RE: REALGetEventInstance returns NULL
> I am able to see the NULL returned in the debugger( and the event is not
> called ).
>
> I should probably mention that I am using VS 2003 to build and debug the
> plug-in and RB 5.5.5 to build the app. I'm not sure if that makes a
> difference.
>
> Darren
>
> -----Original Message-----
> From: realbasic-plugins-bounces at lists dot realsoftware dot com
> [mailto:realbasic-plugins-bounces at lists dot realsoftware dot com]On Behalf
> Of
> Alfred Van Hoek
> Sent: July 21, 2005 11:56 AM
> To: REALbasic Plugins
> Subject: Re: REALGetEventInstance returns NULL
>
>
>
> On Jul 21, 2005, at 11:41 AM, Darren Boon wrote:
>
> >
> > I am trying to use an event that I have defined in my control without
> > much
> > success.
> >
> > This is how I have defined it:
> >
> > typedef void (*InitEventPtr)( REALcontrolInstance instance );
> >
> > static REALevent SectionEditorEvents[] = {
> > { "Initialize" },
> > };
> >
> > This is how I am using it:
> >
> > InitEventPtr init = (InitEventPtr)REALGetEventInstance( instance,
> > &SectionEditorEvents[0] );
> > if( init != NULL )
> > init( instance );
> >
> > The event shows up in the RB IDE and I can add code it it, but my
> > plug-in
> > always gets a NULL function pointer from REALGetEventInstance. What
> > could be
> > preventing my plug-in from getting the function pointer?
> >
> >
>
> How do you know it gets a NULL? Is it because the event is never been
> called?
>
> Alfred
>
> _______________________________________________
> Unsubscribe or switch delivery mode:
> <http://www.realsoftware.com/support/listmanager/>
>
> Search the archives of this list here:
> <http://support.realsoftware.com/listarchives/lists.html>
> _______________________________________________
> Unsubscribe or switch delivery mode:
> <http://www.realsoftware.com/support/listmanager/>
>
> Search the archives of this list here:
> <http://support.realsoftware.com/listarchives/lists.html>
>
>
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>
|