Hi,
I have a .txt file that I am reading in line by line, and on each line I want to find and replace certain words. Is there a function that is available that will replace the word with another word if it is in the line multiple times? If not, is there an easy way to do this? I was looking at the "at" function, but that only finds one instance of the word, so if there would be more than one occurance of the word on the line, I would be SOL.
Thanks for your help.
"Pin me. Perl me."
Regards,
Chris
I have a .txt file that I am reading in line by line, and on each line I want to find and replace certain words. Is there a function that is available that will replace the word with another word if it is in the line multiple times? If not, is there an easy way to do this? I was looking at the "at" function, but that only finds one instance of the word, so if there would be more than one occurance of the word on the line, I would be SOL.
Thanks for your help.
"Pin me. Perl me."
Regards,
Chris