Your handle goes out of scope when the code reaches the closing brace. You
need to have a handle that remains valid while being assigned to the field.
Matt
----- Original Message -----
From: "Joe" <[EMAIL PROTECTED]>
To: "Palm Developer Forum" <[EMAIL PROTECTED]>
Sent: Sunday, May 12, 2002 2:08 PM
Subject: Re: Non-word-aligned handle
> --- Alexandre Kazantsev <[EMAIL PROTECTED]> wrote:
> >
> > I'm getting the "Non-word-aligned handle" SysFatalAlert"
> > from the code
> > {
> > char nullstring = 0;
> > MemHandle initH;
> >
> > initH = MemHandleNew(1);
> > StrCopy( (char *)MemHandleLock(initH), &nullstring);
> > MemHandleUnlock(initH);
> > FldSetTextHandle(fieldptr_Query, initH);
> > //!!! The line above generates the error !!!
> > }
>
> Is fieldptr_Query actually a FieldType * that has been properly
> initialized and is in scope?
>
>
> __________________________________________________
> Do You Yahoo!?
> LAUNCH - Your Yahoo! Music Experience
> http://launch.yahoo.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/