Hello Tim, That is very similar to what I am looking at doing. The only problem is I don't want to replace anything in between In: and Your; I just want to extract anything between In: and Your and store it as a variable.
Regards, Dan -----Original Message----- From: Timothy Johnson [mailto:[EMAIL PROTECTED]] Sent: Friday, 8 March 2002 11:44 AM To: Daniel Falkenberg; [EMAIL PROTECTED] Subject: RE: Finding words between words... I think this will do what you're asking, but I can't test it. $line =~ s/In:(.*)Your/In:($newstring)Your/; # substitute In: followed by any number of anything followed by Your # with In: followed by $newstring followed by Your -----Original Message----- From: Daniel Falkenberg [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 07, 2002 2:55 PM To: [EMAIL PROTECTED] Subject: Finding words between words... Hey all, Does any one know how I would go about finding everything between the words of... In: <AND> Your? So if I have a sentance with the following... Hello all this In: America (New York) Your So is there some perl code that will extract America (New York). Keep in mind tha t everything between In: <AND> Your will change. Thx, Dan -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ------------------------------------------------------------------------ -------- This email may contain confidential and privileged material for the sole use of the intended recipient. If you are not the intended recipient, please contact the sender and delete all copies. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]