in reply to Re^2: How to call cmd line within PERL?
in thread [Newbie Question] How to call cmd line within PERL?
Hi bill5262,
In addition to my other post here's a really quick example:
#!/usr/bin/env perl use warnings; use strict; use IPC::System::Simple 'system'; my $ieeeaddr = 20; system('GPIBSHOT.EXE','/HIDE',"/$ieeeaddr",'/COLOR','/NAME=IMG1', '/SCREEN','/NAME=DAT1','/TRACE2','/END');
Update: The line "use IPC::System::Simple;" should have been "use IPC::System::Simple 'system';", since system is not exported by default!
Hope this helps,
-- Hauke D
|
|---|