Questions tagged [external-process]

168 questions
6
votes
1 answer

Lauch external program in firefox or chrome

We have a custom web app in our intranet that allow users to browse and search our shared file system in a way more appropriate for our organization. as compared to windows explorer/mac finder. However, when the users click on, for example, a link…
Hernan
  • 5,199
  • 5
  • 46
  • 79
6
votes
1 answer

Calling external program from R with multiple commands in system

I am new to programming and mainly I am able to do some scripts within R, but for my work I need to call an external program. For this program to work on the ubuntu's terminal I have to first use setenv and then execute the program. Googling I've…
user3342784
  • 93
  • 1
  • 1
  • 4
5
votes
2 answers

C - going from ncurses ui to external program and back

I'm making a program that displays some info in ncurses, and then opens vim (using system) to allow the user to edit a file. After vim is exited, though, the ncurses screen won't redraw. refresh and wrefresh don't do anything, resulting in the…
ty.
  • 10,411
  • 9
  • 49
  • 63
5
votes
2 answers

No input from ProcessBuilder's InputStream until external process is closed

Whilst building an wrapper for an console application I came across this weird issue where the Input Stream connected to the output (stdout) of the external process is completely blank until the external process exits. My code as below: import…
initramfs
  • 7,625
  • 2
  • 32
  • 56
5
votes
3 answers

Piping data from python to an external command

I've read everything there is on subprocess.Popen but I think I'm missing something. I need to be able to execute a unix program which reads a data stream from a list created in the python script and write the result of that program to a file. From…
Shahar
  • 711
  • 1
  • 9
  • 18
5
votes
3 answers

C# : Redirect console application output : How to flush the output?

I am spawning external console application and use async output redirect. as shown in this SO post My problem is it seems that the spawned process needs to produce certain amount of output before I get the OutputDataReceived event notification. I…
THX-1138
  • 20,006
  • 22
  • 92
  • 151
5
votes
3 answers

A Java program that runs an external "java myprog < input.txt > output.txt"

I want to write a Java program that runs an external "java myprog < input.txt > output.txt" command. The eventual goal is to run this command on two different programs and compare their output similarity from their respective output files. I think…
missthang
  • 51
  • 3
4
votes
3 answers

system() and CreateProcess() / CreateProcessW()

I want to execute a TEST.exe in a C program. While I use system( "TEST.exe output-file" ); I can get what I expected. But CreateProcessW() didn't work properly when I use the following code (see How do I run an external program?): if…
dehiker
  • 71
  • 1
  • 6
4
votes
1 answer

Call popen with environment

In my Lua program i have to catch output from an external program. This external program needs certain environment variables. So i do this: e = "" e = e .. "A=100;" e = e .. "B=Hi;" e = e .. "C=Test;" file = io.popen(e .. "/bin/aprogr") Obviously…
PeterMmm
  • 22,286
  • 12
  • 68
  • 104
4
votes
4 answers

Is there a good way to stream the results from an external process into a Visual Studio output pane?

I have a custom output pane set up in a VsPackage similar to the following: ///-------------------------------------------------------------------------------- /// This property gets the custom output pane.
Dave Clemmer
  • 3,757
  • 12
  • 47
  • 72
4
votes
3 answers

Running multiple external programs

So, I set up a short script which executes an external program (written in Fortran 77). I want to run multiple instances of the program and since I have 8 cores on my computer the simplest solution I found was: import subprocess import os i =…
4
votes
3 answers

How to know if an external process has finished in python?

I am working from a windows platform. In my python script, I can make a call to an external program in the following way: os.system("C:\mainfolder\menu.exe C:\others\file1.inp C:\others\file2.inp") os.popen("C:\mainfolder\menu.exe…
Sarah
  • 325
  • 6
  • 16
4
votes
1 answer

How to detect an external process crash in Java?

I am working on an application that needs to launch a process and wait for its output. Sometimes the process crashes (very often,) but is not really an issue since I have mitigation tasks. The problem is that Windows detects the process crashed and…
Marcelo
  • 2,062
  • 3
  • 22
  • 31
4
votes
0 answers

How to run interactive python script using apache common exec?

I am trying to run a python script using Apache Commons exec.I need to pass some values to python script as python script in an interactive one.How to do it? My attempt was to set values in parent process's input stream.But it's not working for…
Abhijeet Panwar
  • 1,767
  • 3
  • 23
  • 43
4
votes
2 answers

Debugging when my code is started by external program with Process.Start()

Suppose I have a C# WinForms application and it is started by external program simply by using Process.Start(MyModule.exe). I've tried to debug my code by using My project properties->Debug->Start Action->Start external program (with setting proper…
bairog
  • 2,455
  • 3
  • 29
  • 40
1
2
3
11 12