Farzin Ashraghi wrote:

> How can I define "s" in this structure?:
> 
> CharPtr StrIToA (CharPtr s, Long i)
> 
> If I define s=0, it gives me the error message "written directly to
> memory location NULL".  On the other hand, why have I to define
> "s" if the whole structure gives me the CharPtr that I need.

It returns just "s". You have to allocate memory for s:

        s = MemPtrNew(number_of_bytes);

but don�t forget to deallocate:

        MemPtrFree(s)


-- 
 Tschau,            ICQ 28589118                   PGP-Key available
      Daniel        [EMAIL PROTECTED]
                    http://www.dseifert.de/        Berlin, Germany

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

Reply via email to