sharon has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I am quite new to the perl world. I can open files like wordpad.exe or notepad.exe in my perl using system or exec command. What if there is a situation like running source file(which is not an exe file) using an exe like VC++ or Labview. Please help..or just give me a hint. My intention is to run a Labview 'VI' file which is not executable by itself.I need to open the file using 'Labview' and press the run button to run the 'VI' Thanks in advance..!!!

Replies are listed 'Best First'.
Re: Executing source file -need help.
by GrandFather (Saint) on Feb 06, 2009 at 04:12 UTC

    Consider how you would perform the same action from the command line, then use system or exec as you do with other applications. There is no special Perl magic involved, just a knowledge of your particular OS and the applications you are using with it.


    Perl's payment curve coincides with its learning curve.
Re: Executing source file -need help.
by Corion (Patriarch) on Feb 06, 2009 at 07:25 UTC

    If GrandFather's advice of using the command line is not applicable (but Google tells me that it is), then you can also take a look at Win32::GuiTest to send mouse clicks and (preferrably) keystrokes to any Windows application (except to console applications).