HI, I know that SysGetTrapAddress() works on both OS4.1 and OS5.0 but I need to know if I can just assign a variable to a function without Using SysGetTrapAddress().
So, to answer my question what is the correct way to obtain a function Address without using SysGetTrapAddress()? Regards -----Original Message----- From: Ben Combee [mailto:[EMAIL PROTECTED]] Sent: September 20, 2002 12:17 PM To: Palm Developer Forum Subject: Re: Get a function address At 08:16 PM 9/20/2002 +0200, you wrote: >Am Fre, 2002-09-20 um 19.55 schrieb Danny Wong: > >Hi, > > > How do I get the address of a system function? > > Eg: For SysTaskDelay() I want to get the address of it. > > I know I can get it using the SysGetTrapAddress() but can I > > Just do this? > > > > UInt32 taskdelay = SysTaskDelay; > > MemPtr task = SysTaskDelay; > >No. Refer to the sdk for details why this won't work. > >Why don't you want to use SysGetTrapAddress() anyway? Remember that the >whole issue won't work under PalmOS 5 (unregarding of how you try to get >the address). Actually, SysGetTrapAddress does work on Palm OS 5. The call will return the address that PACE will interpret as a system call if used as a function pointer. SysSetTrapAddress will not work on Palm OS 5, but the Get operation is OK. -- Ben Combee <[EMAIL PROTECTED]> CodeWarrior for Palm OS technical lead Palm OS programming help @ www.palmoswerks.com -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/ -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
