You could post an appStop as has been suggested, or perhaps more gracefully.
Do something like this...
UInt32 PilotMain (UInt16 cmd, MemPtr cmdPBP, UInt16 launchFlags)
{
if (cmd == sysAppLaunchCmdNormalLaunch) {
if (<routine that opens serial port>) {
return <an error code if you care>;
}
<Rest of init, etc..>
}
}
Patrick Ouellet <[EMAIL PROTECTED]> wrote in message
news:31514@palm-dev-forum...
>
> How can I make my app close if I detect an error.
>
> Like I would like my apps to stop and exit
> if I can't open the serial port.
>
> Or I could only fake a Application Buton click.
> (the one with the shape of a house)
>
>
> And can someone tell when Bitmap family appeared.
> ( I mean with which OS 2, 3, 3.1 ??? )
> --
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
> Patrick Ouellet - Programmeur S�nior
> [EMAIL PROTECTED]
> Recherche & Devloppement
> Les Entreprise Microtec inc.
> =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
>
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/