You have to "prepare" the target string before passing it to 
TxtFindString. The best way to do this is to call 
TxtGluePrepFindString, in the PalmOSGlue library.

Note that when your app receives the sysAppLaunchCmdFind launch 
command, the FindParamsType.strToFind field contains the results of 
calling TxtPrepFindString with the string entered by the user in the 
Find form (the FindParamsType.strAsTyped string).

-- Ken

At 12:00am -0700 00-06-27, Palm Developer Forum digest wrote:
>Subject: Re: TxtFindString Error....
>From: "Sam Trimble" <[EMAIL PROTECTED]>
>Date: Mon, 26 Jun 2000 15:39:35 -0700
>X-Message-Number: 66
>
>Thanks, that solved the Null problem anyway... But now I'm wondering if the
>function even works the way it is supose to.. It always returns a 0 for
>'someULong' even though I know it isn't suppose to be...
>
>
>"McMicken, Steven" <[EMAIL PROTECTED]> wrote in message
>news:15455@palm-dev-forum...
>  >
>  > Just a guess, but you may have to provide a variable of type UInt16 for
>the
>  > last parameter.  The function is probably trying to replace the return
>value
>  > of "outLength" in there.
>  >
>  > Regards,
>  >
>  > Steve

At 12:00am -0700 00-06-27, Palm Developer Forum digest wrote:
>Hey,
>  I'm trying to use the following code to get the starting posistion of a
>string but I always get a "NULL result ptr...." error. Can someone help me
>out on what I'm doing wrong here?
>
>ULong  someULong = 0;
>
>if (TxtFindString(myCharPtr, "String I'm Searching For", &someULong, NULL));

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