You may want to try using the following functions from the unit: strutils
ExtractWordPos
WordPosition
Both functions allow you to define delimiters for words (eg ' ', ',') and come with a predefined set of delimters (StdWordDelims)
StdWordDelims = [#0..' ', ',', '.', ';', '/', '\', ':', '''', '"', '`'] + Brackets;
Hope this helps