One more thing. My original goal was to replace several strings on a line.
Do I need to do the "expansion" thing for each string that I want to
replace? For example if I have a file that contains Unicode text and it has
a line "Testing 1 2 3" in it and I want to replace the 1 with One, 2 with
Two, and 3 with Three. The following does not work. It works with ANSI files
but not Unicdoe.
my $string = "Testing";
$string =~ s/(.)/$1\x00/g; # expand ANSI to UTF-8 (not the most
efficient, but...)
while (<FILE>)
{
if (/$string/o)
{
s/1/One/;
s/2/Two/;
s/3/Three/;
print;
}
}
Any suggestions?
Thanks again.
Kevin Burton
[EMAIL PROTECTED]
---
You are currently subscribed to perl-win32-users as: [archive@jab.org]
To unsubscribe, forward this message to
[EMAIL PROTECTED]
For non-automated Mailing List support, send email to
[EMAIL PROTECTED]