"[A-Za-z_]" is the same as \w
so if you want to include dashes and ' your pattern would be
[A-Za-z'_-]
Surround that by \b for word bounderies and you've got what you need.
Try this:
// mySourceText is just my source text i'm checking... put whatever
you want.
var wordPattern:RegExp = /\b[A-Za-z'_-]+\b/gi;
var wordMatch:Array;
//wordMatch = wordPattern.exec(mySourceText);
do
{
wordMatch = wordPattern.exec(text);
if (wordMatch != null) trace(wordMatch);
} while (wordMatch != null)
--- In [email protected], "jmfillman" <[EMAIL PROTECTED]> wrote:
>
> They sure are confusing. I spent several hours reading various
sites
> last night and everything I tried didn't work; they gave me
nothing.
> Seems not everything works with Flex.
>