Try this..
SysNotifyParamType *eventP = (SysNotifyParamType *) cmdPBP;
SysNotifyVirtualCharHandlingType *vchr =
(SysNotifyVirtualCharHandlingType *) eventP->notifyDetailsP;
if ( vchr->keyDown.chr == virtual character)
{
your code...
}
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Patrick
Lucas
Sent: Tuesday, July 27, 2004 9:10 PM
To: Palm Developer Forum
Subject: Re: Responding to hardware button presses
Guys
I registered my application to respond to virtual key events in the
following way
SysNotifyRegister(iCard, ID, sysNotifyVirtualCharHandlingEvent, NULL,
sysNotifyNormalPriority, 0);
and yet nothing happens when I press a hardware button.
Any ides why?
I'v attached my PilotMain() function for you to have a look at.
"Patrick Lucas" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Guys
>
> I have a program which puts an icon on the command bar when it is
activated
> and carries-out some action when the icon is clicked. It works
perfectly!
>
> I now wish to have it carry out the same action when a hardware button
is
> pressed. I immagine I have to register the program for the hardware
button
> and then carry-out some action when that button is pressed.
>
> Can anyone here tell me what the functions that I need to call are?
>
> Many thanks
>
> Patrick
>
>
>
>
--
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/