Thanks Gabriel - your suggested code s/(SCTN:\s*)(\w+)/$1\u$2\E/g;
is an improvement - it does capitalise the first letter - but only of the first word after "SCTN: " so i get something like SCTN: This is a section name What I need is SCTN: This Is A Section Name hope that makes sense! :) --- Gabriel Cooper <[EMAIL PROTECTED]> wrote: > > > Bis wrote: > > > I want to make the case of the first letter of all > the words in a > > selected string to upper case. The code > > s/\b(\w+)/\u$1\E/g; > > enables me to do this for the whole document. > > But the string I want to match and operate on is > all instances of text > > following the string > > SCTN: > > as in > > SCTN: News Analysis > > or > > SCTN: Special Report > > But when I try > > s/(SCTN:\s*)\b(\w+)/$1\u$2\E/g; > > nothing seems to change? : ( > > Bis > > My guess (without actually trying) is the word > boundary marker (\b). > Since you're grabbing all preceding whitespace you > can't (in theory) > expect it to find whitespace before your word. So... > try this: > > s/(SCTN:\s*)(\w+)/$1\u$2\E/g; > > > ________________________________________________________________________ Want to chat instantly with your online friends? Get the FREE Yahoo! Messenger http://uk.messenger.yahoo.com/ -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]