This post describes how to keep a child process alive in a BASH script:
http://stackoverflow.com/questions/696839/how-do-i-write-a-bash-script-to-restart-a-process-if-it-dies
This worked great for calling another BASH script.
However, I tried executing something similar where the child process is a Python script, daemon.py which crea...
I am starting a server application (normally to be started from the Unix command line) by using Runtime.getRuntime().exec("path/mmserver"). My problem is now that as long as my Java program, which started that server runs, the server is correctly accessible (from command line and other programs). But when my Java program exits the sever ...
Certainly we should call Dispose() on IDisposable objects as soon as we don't need them (which is often merely the scope of a "using" statement). If we don't take that precaution then bad things, from subtle to show-stopping, might happen.
But what about "the last moment" before process termination? If your IDisposables have not been...
Hello, I'm trying to find if a window with specific has been open by a Process. That process spawns multiple windows, and I need to check them all.
I have no trouble finding the process, with
foreach (Process p in Process.GetProcesses())
{
if (p.MainModule.FileName.ToLower().EndsWith("foo.exe"))
FindChildWindowWithText(p); //do ...
I want to create a Mono application to start and stop several processes. I only need to be able to start and stop the processes from the Mono application, I do not need any advanced features of managed processes. Users will be able to customize the available processes from a "preferences" menu.
The problem is, that I also need to be abl...
Overview: I'm interested in learning more about the .NET4 "In-Process Side-by-Side Execution" of assemblies, and need additional information to help me demystify it.
Motivation: The application in question is built against .NET2, and uses two third-party libraries that also work against .NET2. The application is deployed (via file copy...
On Windows I've started a program "async.cmd" with a ProcessBuilder like this:
ProcessBuilder processBuilder = new ProcessBuilder( "async.cmd" );
processBuilder.redirectErrorStream( true );
processBuilder.start();
Then I read the output of the process in a separate thread like this:
byte[] buffer = new byte[ 8192 ];
while( !interrupt...
In Linux (CentOS 5.4), how do you force a process to stop locking a file system without killing the process?
I am trying to get my Java Webstart Application, running locally, to eject a CD. I do not have this problem if I am just browsing through the files using a JFileChooser, but once I read the contents of a file, I can no longer eje...
I'm looking for a simple and light tool for tracking ideas and bugs for small physics lab team (4 members). Bugzilla and Trac have too much fields and other stuff for us. I don’t think that we need more than issue descriptions and simple categorization. But we are not happy with text and excel files suggested here. Could you please advis...
Hi,
I am new to WMI and System.Diagnostics etc.
I need to write something (a service?) that monitors several processes for CPU Usage %.
When I am in Task Manager, the CPU column is the one that I want (i.e. the percentage).
I need to be able to run this on a remote machine, and have it check the CPU Usage
every second or so. When the us...
I've created a Windows Service that accepts commands from remote machines via WCF. One of those commands is to run a specified executable (let's ignore the security implications of such functionality).
In my Service I am using Process.Start() to run the executable. All works well if the executable is local to the machine, but if it is o...
Hi,
maybe the topic isn't quite precise.. i want to write in c# (gtk#-2.0) an app which opens another app hidden and later shows that app. For now i know only how to open hidden app... in windows...:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Diagnostics;
namespace do_kasacji
{
...
Hi !
When designing a web application (or something else), it's good to have a workflow, and it's better to have a well ordered one.
Starting with this idea in mind, I'd like to know what is your process from having an idea to maintain this great working project.
For me actually, the process is the following one :
Having the idea
Ch...
Hello
I am interested if calling Process.Refresh() is mandatory when waiting for the process to terminate by checking Process.HasFinished property?
I have a piece of code that works fine without the Process.Refresh() call, however I am curious weather this is a coincidence? I can see that a msdn example has the Process.Refresh() call.....
Below I'm trying to match certain nodes.
<xsl:template match="nodes">
<element>
<xsl:apply-templates select="nodes" mode="different" />
</element>
</xsl:template>
Now, there are multiple ways of processing for the same nodes. I want to use this different way of processing within the current way of processing. That'...
I've been tinkering with a regex answer by yukondude with little success. I'm trying to kill processes that are older than 10 minutes. I already know what the process IDs are. I'm looping over an array every 10 min to see if any lingering procs are around and need to be killed. Anybody have any quick thoughts on this?
Thanks, Steve
ps ...
Hi All,
I have read in many forums that mapped drives are not accessible from a service as no user is logged on.
Question 1) I tried making my service as a log on - as some account and i had my network drive mapped in that very account. The service still cannot access it. Why?
Question 2) From the same sevice, i invoke another process...
Hello,
I need to find out is Process is running on remote machine or not, I know process id and remote pc ip. How to do that?
I have tried code below but do not find way to pass credentials to login to remote machine. Using code below I get access denied as expected.
Process engineProcess = Process.GetProcessById(PID, IP);
Regards,
T...
Good afternoon.
I'm starting programming in java and blackberry.
I am developing an application with three windows, which I will show basic information about the device, these windows are already done and working.
I need to create a process running in the background, this process will run every 10 minutes.
As I make this process run in t...
Hi everyone
I've read many post looking for my answer, but all are similar to this:
http://stackoverflow.com/questions/1610743/reading-excel-files-in-vb-net-leaves-excel-process-hanging
My problem is that I don't quit the app...
The idea is this:
If a User has Excel Open, if he has the file I'm interested in open... get that Excel in...