Somebody wrote:
AA> static FieldPtr SetField(UInt16 formID, UInt16 fieldID, MemPtr str)
AA> {
AA> StrCopy(p,str); // <------------------------
A.Kazantsev wrote:
> The error message suggests that the argument must be cast to the types
> shown. Try StrCopy((char*)p, (char*)str).
I would think it'd be better to change the type of the last argument
to the function SetField() to "const Char *". That way, no cast is
needed.
Also, the first argument already doesn't need to be cast: the
compiler is saying that it's an "{lval} char *", which should
be compatible with a variable declared as CharPtr.
- Logan
--
For information on using the Palm Developer Forums, or to unsubscribe, please
see http://www.palmos.com/dev/support/forums/