Thanks Mate, worked like a treat. Colin
-----Original Message----- From: Aman Thind [mailto:[EMAIL PROTECTED]] Sent: Friday, December 13, 2002 16:39 To: Johnstone, Colin Subject: RE: Regex question Just add another backslash to the "Substitute With" part of the expression as in : $paragraph = 'aman said "This might be a solution to your troubles!"'; $paragraph =~ s/\"/\\\"/g; print $paragraph; The first backslash "escapes" the \ and so you need a second to escape the double quote. -aman. -----Original Message----- From: Johnstone, Colin [mailto:[EMAIL PROTECTED]] Sent: Friday, December 13, 2002 11:00 AM To: '[EMAIL PROTECTED]' Subject: Regex question Gidday all, I have a paragraph of text, I want to convert any double quotes around quoted text to \" is this the correct reg ex $paragraph =~ s{\"}{\\"}g; Thanking you in anticipation Colin Johnstone -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]