S
sebastien.godier
Hello,
My Perl script is first reading a text file containing a list of
computer names I want to run a command against.
The name of each computer is stored inside $_ variable.
So, I'm trying to generate my external command using this variable
inside a loop. Like this
system ("REG QUERY \"\\\\$_\\HKLM\\SOFTWARE\\MICROSOFT\\Internet
Explorer\\Main\" /v \"Start Page");
The problem is that $_ is not substituted at all. If I replace $_ by a
real computer name, it works. But I don't know how to declare $_ as a
variable in this line.
Any idea welcome!
Thanks
Sebastien
My Perl script is first reading a text file containing a list of
computer names I want to run a command against.
The name of each computer is stored inside $_ variable.
So, I'm trying to generate my external command using this variable
inside a loop. Like this
system ("REG QUERY \"\\\\$_\\HKLM\\SOFTWARE\\MICROSOFT\\Internet
Explorer\\Main\" /v \"Start Page");
The problem is that $_ is not substituted at all. If I replace $_ by a
real computer name, it works. But I don't know how to declare $_ as a
variable in this line.
Any idea welcome!
Thanks
Sebastien