473,830 Members | 2,086 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Execution of an Executable File in a Seperate Process


Hi,

I have a working windows service,it is looking for files
on the disk
and when some of the files are cupdated it calls an
executable. But it
takes a lot of time(about 10 minutes) to run the
executable.So while
that executable is running,if I try to stop the windows
service while
the executable(MYPR OGRAM.EXE) is running,it will wait for
a time(about
20 seconds) for the main windows thread to abort.If it
does not finish
its work, the service process is killed AUTOMATICALLY and
tells
something like "the service did not stop ina timely
fashion".
As the windows service will never be able to finish its
work under a
minute,
my service always is stooped by WINDOWS and got the
message "the
service did not stop ina timely fashion".

I need a asynchronous way to execute the MYPROGRAM.EXE in
a different
process than the windows service process so that even if
the service
stops,if MYPROGRAM.EXE will continue to run..

One way to do is to call a web service method
asynchronously which
executes MYPROGRAM.EXE ...So the .NET code for the
windows service
will not suspend when it calls the windows service
method. and will
stop ina timely fashion when it is signaled. But I think
there should
be better ways of implementing it without using IIS.

I'll appreciate very much if you help...
Jul 21 '05 #1
0 1239

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
5208
by: Caroline | last post by:
I'd like to launch an executable file from a web page. Basically, the user enters seven parameters and then clicks a button to generate a graph. The input is written to a file and then read by the exe. The exe then generates a graph based upon the input parameters. I am reading about the Process class and wondering if that is the best approach to this. Can you recommend a KB article?
75
9915
by: Beni | last post by:
I have been programming in C for about a year now. It sounds silly, but I never took the time to question why a C(or C++ or Java) program execution begins only at the main(). Is it a convention or is there some deeper underlying reason?
0
1354
by: Jorge | last post by:
I'm writing an application that uses system.diagnostics to run an executable that will allow me to create a map. However the program fails to start or if its start it is not creating any output. I have a batch file with the exact same code and it does not work. Can anyone help? This is the code: Process p1 = new Process(); p1.StartInfo.FileName = programName2; p1.StartInfo.Arguments = arg2; p1.StartInfo.RedirectStandardOutput = true;
0
904
by: Varadha | last post by:
Hi, I am need to have Mutiple Instance of a executable (process.exe) i my application. My application will be listening for request in a port. It will be done by a seperate executable(listener.exe) .Once it get request it has to send the request to one of the process.exe executable by using a load sharing technique. Once the process.exe performs the proces it has to send the response back to the requesting system. All these executable...
0
285
by: belgi | last post by:
Hi, I have a working windows service,it is looking for files on the disk and when some of the files are cupdated it calls an executable. But it takes a lot of time(about 10 minutes) to run the executable.So while that executable is running,if I try to stop the windows service while
17
5110
by: romixnews | last post by:
Hi, I'm facing the problem of analyzing a memory allocation dynamic and object creation dynamics of a very big C++ application with a goal of optimizing its performance and eventually also identifying memory leaks. The application in question is the Mozilla Web Browser. I also have had similar tasks before in the compiler construction area. And it is easy to come up with many more examples, where such kind of statistics can be very...
15
2210
by: polas | last post by:
Hi everyone - I have a question. I am just playing around with C (I realise there are better ways to do what I want, but I would like to do it this way to increase my understanding of C) and would like to read an executable file in to a portion of memory and then pass execution to this and execute the file. However, I can not get it working and my efforts have resulted in a Seg Fault. Below is the code I have got #include "stdio.h"
4
5141
by: Kerem Gümrükcü | last post by:
Hi, i wonder that the Process.Start(...) needs full path to the executable to start it, even the executable is listed in the PATH Variable and can be launched from any console on my system. Is it possible to do the same from Process.Start(...)? How can i set the Process Executon Environment for the Process, so that the call to Start(...) will resolve the path to the Exe from the PATH Env. and run it. Is this possible...? Maybe i miss...
5
2866
by: Guillermo Antonio Amaral Bastidas | last post by:
Hi everybody, I have a quick and probably dumb question, keep in mind I just dumped my old love FastCGI + Perl for it's younger hotter friend PHP5. If the user calls a time consuming script and then stops or refreshes the browser before the script had time to finish will Apache kill the script mid execution or will it let it finish ? I ask this stupid question because this seems to be happening in one
0
9793
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10493
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10206
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9315
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7747
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6951
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5780
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3960
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3076
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.