W
wxdeveloper
Hello
I want to read a BAT file to some array and then process it line by
line.
The problem is that the BAT file has some DOS variables inside (for
example, %VARIABLE%).
I read the file to an array like this:
@my_array = <FILEHANDLE>
Then I want to process each line
foreach (@my_array)
{
printf "$_";
}
The problem is that perl somehow assums that %V is a variable and
tries to replace it with a value.
The result is that I get string 0ARIABLE%.
Is there any way to prevent this?
Thank you
J. Grabis
I want to read a BAT file to some array and then process it line by
line.
The problem is that the BAT file has some DOS variables inside (for
example, %VARIABLE%).
I read the file to an array like this:
@my_array = <FILEHANDLE>
Then I want to process each line
foreach (@my_array)
{
printf "$_";
}
The problem is that perl somehow assums that %V is a variable and
tries to replace it with a value.
The result is that I get string 0ARIABLE%.
Is there any way to prevent this?
Thank you
J. Grabis