Try placing both the perl and C program in a single directory and remove
the path and just give only the command to run the perl program. If that
runs,
Then include
System("cd \\"); command before your statement.
Regards,
Karthikeyan M
Love is magic,
Rem'ber,
Magic is an illusion.
________________________________
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of Sumit Chawla
Sent: Thursday, March 29, 2007 4:07 PM
To: [email protected]
Subject: Re: [c-prog] Re: starting a perl program from a c program
On 29 Mar 2007 01:42:12 -0700, sanofsans <[EMAIL PROTECTED]
<mailto:sanofsans%40yahoo.com> > wrote:
>
> Thanks for your help. I tried that, but I am getting an error.
> This is my program:
>
> #include <stdio.h>
>
> void main()
> {
> /*system("perl C:\path\to\script"); */
> system("perl C:\\Documents and
> Settings\\Done\\Desktop\\ActivePerl-
> 5.6.1.638-MSWin32-x86\\ActivePerl\\Perl\\bin\\helloworld.pl");
>
> return;
> }
>
> This is the error:
> Can't open perl script "C:\Documents": No such file or directory
> Press any key to continue
>
> Any suggestions?
>
>
>
Try including the path of perl script inside the single quotes.
--
Regards
Sumit Chawla ("eNetra : Hail the Invention")
"Computers are useless. They can only give you answers.":Pablo Picasso
[Non-text portions of this message have been removed]
**************** CAUTION - Disclaimer *****************
This e-mail contains PRIVILEGED AND CONFIDENTIAL INFORMATION intended solely
for the use of the addressee(s). If you are not the intended recipient, please
notify the sender by e-mail and delete the original message. Further, you are
not to copy, disclose, or distribute this e-mail or its contents to any other
person and any such actions are unlawful. This e-mail may contain viruses.
Infosys has taken every reasonable precaution to minimize this risk, but is not
liable for any damage you may sustain as a result of any virus in this e-mail.
You should carry out your own virus checks before opening the e-mail or
attachment. Infosys reserves the right to monitor and review the content of all
messages sent to or from this e-mail address. Messages sent to or from this
e-mail address may be stored on the Infosys e-mail system.
***INFOSYS******** End of Disclaimer ********INFOSYS***
[Non-text portions of this message have been removed]