Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
call unix commands through program
Name: era Date: January 7, 2004 at 10:44:52 Pacific OS: ScoUnix,windows CPU/Ram: 128
Comment:
hi all, Can we call(run) unix commands through a java program? Plzz let me know.... Actually i want the commands like "ls" to run automatically when some event occurs & then i want to store its output in a file by redirecting it.
if anybody knows the solution or link...plzz tell me..waiting 4 ur reply.
Name: wt (by think) Date: January 7, 2004 at 18:31:35 Pacific
Reply:
yes. In C, function "system" will do, in Java, I can't remember which class it is, try searching the java official website.
hope that help. :)
wtk
0
Response Number 2
Name: anonproxy Date: January 7, 2004 at 21:02:41 Pacific
Reply:
This is found in the runtime object (specifically, Runtime.getRuntime()). This makes your code system dependent.
Example here. Spend 60 seconds reading about the Runtime object. It should be easier to find, but the majority of the class goes against the preachings of portability. Well, its not Sunday ;)
0
Response Number 3
Name: era Date: January 8, 2004 at 07:27:29 Pacific
Reply:
hi,
Thanx a lot to wtk & anonproxy for replying me. I am now trying to execute the commands using information given by u both.
Summary: Hellow, How to exploit basic Unix (linux) commands such as "rm","cd","ls","grep" in C programming? Firstly, I tried bash script but it is not convenient to concern with real number computing. A...
Summary: Dear all i wonder if there is a program or a way to excute unix command through vb 6.0 basicly i want to make a vb 6.0 programm that open files on unix server and retrive the result. thanks ...
Summary: HOW CAN I RUN UNIX COMMANDS in VB6? i have started TELNET using APPACTIVATE and Shell function how can i login into the telnet using vb6 ? call me on Puneet 9821308954 email me puneetpalbedi@gmail.com...