At 12:00am -0800 01-02-24, Palm Developer Forum digest wrote:
>Subject: Re: FldGetTextLength (fldP) and StrLen (FldGetTextPtr (fldP))
>From: [EMAIL PROTECTED]
>Date: Fri, 23 Feb 2001 12:09:15 -0000
>X-Message-Number: 88
>
>What if you're using multibyte character (non-English)?
>
>  > Are there any circumstances when
>
>  >           FldGetTextLength (fldP) != StrLen (FldGetTextPtr (fldP))

Though FldGetTextPtr() can return NULL for an empty field which 
hasn't been edited.

>That is exactly what I am asking BUT I received no response yet.
>Studying my Field.c [see ValidateField()],
>it's clear that in the released version of the OS 3.5 source files
>the above two are always the same. BUT then I never had a chance to see
>a multi-byte Field.c.

The length of a string in Palm OS is the number of bytes in the 
string that precede the terminating '\0' byte. It is not a count of 
the number of characters, and thus the behavior doesn't change when 
running on a Japanese system which uses a multi-byte character 
encoding.

-- Ken

Ken Krugler
TransPac Software, Inc.
<http://www.transpac.com>
+1 530-470-9200

-- 
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