[Coco] "C string searching question

Bill Pierce ooogalapasooo at aol.com
Tue Oct 2 00:49:56 EDT 2012


<Replace the inner loop with:
 < if (strstr (records[cnt].recname, srchstr))

That looks like what I'm looking for.
Will it find any occurance of srchstr from within the records[cnt].recname?

Thanks,
Bill P

Music from the Tandy/Radio Shack Color Computer 2 & 3
https://sites.google.com/site/dabarnstudio/
Bill Pierce
ooogalapasooo at aol.com




-----Original Message-----
From: Mark McDougall <msmcdoug at iinet.net.au>
To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
Sent: Tue, Oct 2, 2012 12:37 am
Subject: Re: [Coco] "C string searching question


On 2/10/2012 2:01 PM, Bill Pierce wrote:

> <I don't suppose you have access to library functions like strlen() and
> <strchr() and strstr() in that context, do you?
> 
> Yes, they are supported. 

Replace the inner loop with:
  if (strstr (records[cnt].recname, srchstr))

Regards,

-- 
|              Mark McDougall                | "Electrical Engineers do it
|  <http://members.iinet.net.au/~msmcdoug>   |   with less resistance!"

--
Coco mailing list
Coco at maltedmedia.com
http://five.pairlist.net/mailman/listinfo/coco

 



More information about the Coco mailing list