HI,
     What you are trying to do, I guess, is to launch a subapplication,
which cannot be lauched independentely, from a host application. You can
try this:

1. Make your subapplication as an application only, and if the launch code
is sysAppLaunchCmdNormalLaunch, then exit
2. In this subapplication handle your own user-defined launch code (see
PhoneLookup.c. provided with Metrowroks in examples) and do the handling as
you wish to.
3. From host application use SysAppLaunch (...) to launch the
subapplication with appropriate launch code (the one you handled earlier in
subapplication) to call the subapplication.
4. Once the subapplication is over, the control will return back to the
host application along with any parameters you wish to return back.

See Ref1.pdf (pg. 84) and Ref2.pdf (pg. 62) which are distributed with
CodeWarrior

Hope you'll find it useful.

Warning:- Don't use globals in subapplications.

Deepali Bhardwaj
ITIL, GROUP USHA
New Delhi, India
www.palmix.itil.com




I have an interesting, though somewhat academic question.

Is it possible to write an application that is not loaded as an
application, but
rather is stored as a database entry on the Palm, then when selected by a
"host"
application, the "database-based" application runs? When it finishes, it
would
launch the parent application with a custom launch code and the user would
be
returned to where they started - sort of.

The problem I'm trying to solve is one of having hundreds of "applets"
available
to be run on the Palm at one time. These programs are very small, and there
are
potentially 1000's of them. It would be a shame to burn up 1000 creator ids
for
these guys, yet I am intrigued by the idea of having each one a totally
self
contained program.

I'd tell you what I have in mind for them to do, but then I'd have to kill
you :).

-Tim
--
Tim Hewitt
Principal Software Engineer
Fairchild Semiconductor







Reply via email to