<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=US-ASCII">
<META content="MSHTML 6.00.2900.3086" name=GENERATOR></HEAD>
<BODY id=role_body style="FONT-SIZE: 10pt; COLOR: #000000; FONT-FAMILY: Arial"
bottomMargin=7 leftMargin=7 topMargin=7 rightMargin=7><FONT id=role_document
face=Arial color=#000000 size=2>
<DIV>
<DIV>How about something like this:</DIV>
<DIV> </DIV>
<DIV> put "This is a test." into myLine</DIV>
<DIV> replace " " with "*" in myLine</DIV>
<DIV> put fld 1 into myField</DIV>
<DIV> replace ". " with ".#" in myField (note : period + space. use
two spaces if needed)</DIV>
<DIV> replace space with "*" in myField</DIV>
<DIV> replace "#" with space in myField</DIV>
<DIV> if myLine is among the words of myField then return true</DIV>
<DIV> </DIV>
<DIV>
<DIV>Philip Chumbley</DIV></DIV>
<BLOCKQUOTE
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: blue 2px solid"><FONT
style="BACKGROUND-COLOR: transparent" face=Arial color=#000000 size=2>I am
trying to write a function that returns whether a given phrase exists
<BR>in a field as whole words.<BR><BR>e.g.<BR>put "This is a test." into fld 1
(note the punctuation)<BR><BR>whole("This is a tes",fld 1) = FALSE
<BR>whole("This is a test",fld 1) = TRUE.<BR><BR>A bit like trying to get the
line "This is a tes" is among the words of fld <BR>1 to work (obviously
it doesn't), even assuming no punctuation were involved!<BR><BR>I've
returned to this little conundrum many times over the years but have
<BR>yet to solve it.<BR><BR>Any offers?<BR><BR>/H</FONT></BLOCKQUOTE></DIV>
<DIV></DIV>
<DIV> </DIV></FONT><BR><BR><BR><DIV><FONT style="color: black; font: normal 10pt ARIAL, SAN-SERIF;"><HR style="MARGIN-TOP: 10px">See what's free at <A title="http://www.aol.com?ncid=AOLAOF00020000000503" href="http://www.aol.com?ncid=AOLAOF00020000000503" target="_blank">AOL.com</A>. </FONT></DIV></BODY></HTML>