473,396 Members | 1,846 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Executing a .exe console app

I have developed a console app . The .exe is to be executed through a perl program.
I am a newbie to perl , can some provide me some info on this - How to execute the exe from perl. Also the .exe takes two parameters as files, how can i give them ?

Please share any links you have which can provide some help regarding the query here.

Thanks in advance

Regards
Nikhil
Dec 6 '06 #1
4 2336
geek491
21
I have developed a console app . The .exe is to be executed through a perl program.
I am a newbie to perl , can some provide me some info on this - How to execute the exe from perl. Also the .exe takes two parameters as files, how can i give them ?

Please share any links you have which can provide some help regarding the query here.

Thanks in advance

Regards
Nikhil

So u want the console .pl application to run as a .EXE application?

U need to install PAR module using PPM.. open comand prompt and type ppm

ppm> install PAR
...
..
ppm> quit

this will install the par module... to create exe of your program type the following in general cmd prompt

pp -o program.pl program.EXE

this will create an EXE file for u.

hope it helped.
geek491
Dec 6 '06 #2
I guess you dint get my point ..
I will rephrase it again

I already have a tool -> parsing.exe with me . I developed it with VC++.
its a command line tool. It parses a text file and tell me whether a particular string is present or not in that text file.

I want to execute the parsing.exe tool through the perl script.
as in whenever the perl script gets executed the tool should also get executed.

Regards
Nikhil
Dec 6 '06 #3
You possibly mean backtick operators. They work like this:

my $errmessage = `tar -zcf $outfile @files`;

Whatever is between ` and ` will be executed in the command line of current operational system (no matter what system it is).

$errorcode = `any_command.exe any_param`;

if you are not interesting in error code you can execute it like this:

`executable_file.exe`;
Dec 7 '06 #4
GunnarH
83
You possibly mean backtick operators. They work like this:

my $errmessage = `tar -zcf $outfile @files`;
Not quite. What's returned is STDOUT, not STDERR. See the docs.
Dec 7 '06 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: bnp | last post by:
Hi All, I am beginner to PHP. I read that you can run PHP program in a console window. How can I do that? Please help me Bhavik
4
by: Justine | last post by:
Hi All, How can v execute DOS command while executing Console Application written using C#, like cls,dir commnads. Thanz in Advance, Justine
2
by: GG | last post by:
Is there a way to minimize my current console app? Using this code but does not work System.Diagnostics.Process currentProcess=System.Diagnostics.Process.GetCurrentProcess(); ...
15
by: Chakkaradeep | last post by:
Hi all, i have written a Service,now i want to execute another application (for eg;calc.exe) in the service....how will i perform it??... i tried using this.... /**************Executing a...
9
by: Mads W. | last post by:
I want to read an ini file which is located in the same dir as my .exe file. But how can I do that without having to have the excact same dir for all my program installations. Let me try to...
2
by: carolineb2005 | last post by:
I have compiled this simple program which accept arguments on line using System; class HelloWorld { public static void Main(string args) { Console.WriteLine("Hello ", args); } }
4
by: Sampriti | last post by:
I am trying to delete a file from a disk when the user's session ends. So I am putting my file.delete code in Session_End event. I ran the application in the debug mode. When the session timesout...
3
by: Peter Strřiman | last post by:
Hi. I have a web application that needs to run tasks at regular intervals. E.g. it must send out emails every night to people who subscribe to that service. I have come up with one solution,...
1
by: ronaldgranados | last post by:
Hi, I developed an application that generates code to be dinamically execute with reflection. When I used reflection everything seems to work fine until I saw a handle and memory leak. ...
0
by: selvialagar | last post by:
i did a program in vc++.net for ICMP communication using sockets.But when i execute it i received a very slow response...is there any configuration to be made on the server..or any other thing?.. i...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.