Hi.

Ya, you are right. Actually I' m running the code from the book. I have
modified some and it can run. But I don't really know how it works. I mean
there is something out but inside the box is empty. When i click on anywhere
inside the box (PenDownEvent called) and it generates an error.

By the way, I have to confirm my direction where i would like to have an
interface which consists of all the alphabets (A-Z). I have to use the
gadget to design my own interface, am i right? Is there any other code
resources other than i have got from book? I have found the internet and
there is a few of codes from the topic. Can someone tell me?

"Brett A. Hoover" <[EMAIL PROTECTED]> wrote in message
news:91463@palm-dev-forum...
>
> Looks like code out of the Palm Programming Bible.  I ran into this not
too
> long ago working with the examples.
>
> FrmGetGadgetData(form, gadgetIndex);
>
> actually returns a pointer to the data and not a handle.  I had to modify
> from the example in the book and everything worked fine.  Use a data
> pointer.
>
> UInt16 *data = FrmGetGadgetData( frmP, gadgetIndex ) ;
>
> ----- Original Message -----
> From: "Evan Wise" <[EMAIL PROTECTED]>
> To: "Palm Developer Forum" <[EMAIL PROTECTED]>
> Sent: Thursday, July 18, 2002 12:18 PM
> Subject: Re: Free handle problem
>
>
> > there are some possible problems:
> > -have you assigned the gadget memory (ie. MemHandleNew) prior to
> > acquiring the data? (and on the flip side do you free that memory on
> > form destruction?)
> > -do you do this every time the form is recreated?
> >
> > check out :
> > http://www.palmos.com/dev/support/docs/recipes/extended_gadgets.html
> > for more info.
> >
> > the error makes it sound as though you are trying to lock down an
> > invalid chunk of memory.
> >
> > can't say much more without more code though.
> >
> > E/.
> >
> > On Thu, 2002-07-18 at 02:11, quennie wrote:
> > > Hi.
> > >
> > > I have encountered this problem " MemoryMgr.c, Free handle".
> > >
> > > I'm using the Falch.net IDE (C++) and compile a program using the
> Emulator.
> > >
> > > The following code:
> > >
> > > MemHandle dataH;
> > > (void *)dataH = FrmGetGadgetData(form, gadgetIndex);
> > >
> > > if (dataH)
> > > {
> > > UInt8 *data;
> > > data = (UInt8 *)MemHandleLock(dataH); -> error happened from here.
> > > }
> > >
> > > I have the assign the memHandle dataH to a value since i want to make
> use of
> > > the variable to do other things.
> > >
> > > Could someone help me? Do appreciate with the help.
> > >
> > >
> > >
> > >
> > >
> > >
> > > --
> > > 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/
>
>
>
>



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to