Re: Executing a perl script from cocoa - ObjC
Re: Executing a perl script from cocoa - ObjC
- Subject: Re: Executing a perl script from cocoa - ObjC
- From: Bjoern Kriews <email@hidden>
- Date: Fri, 20 Feb 2004 14:01:17 +0100
On 20.02.2004, at 12:12, Ramakrishna Kondapalli wrote:
I want to execute a Perl script (For Ex. ./Users/usr1/per1.sh
<file_name>) from my cocoa - ObjC code and put the output in a file.
How
can I do this?
Thanks & Regards,
simplest way (works in every C program):
#include <stdlib.h>
system("any shell command here > somefile");
For a more Cocoaish solution, take a look at NSTask,
there are various examples on the net, one by Apple,
called Moriarity if I recall correctly,
cocoadevcentral.com has something about it and
the book "Cocoa Programming" explains it pretty well.
Regards, Bjoern
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.