473,320 Members | 2,080 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Polling Another App

Hi,

I've got two applications. The job of the second application is to make
sure that the first application is running; if it's not, it relaunches it.

Is there a good code snippet that somebody can point me to that would
accomplish this?

Regards,
Scott
Mar 11 '08 #1
1 924
Scott McNair <sm*****@beachexpress.takethispartout.comwrote in
news:Xn*********************************@207.46.24 8.16:
Is there a good code snippet that somebody can point me to that would
accomplish this?
As is the case a lot of times, I found the solution within a minute of
posting the question:

Private Sub CheckForApp()
Dim myProcesses() As Process
myProcesses = Process.GetProcessesByName("MyApp")
If myProcesses.Length = 0 Then
'Launch the app
System.Diagnostics.Process.Start("P:\ath\to\MyApp. exe")
End If
End Sub
Mar 11 '08 #2

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

Similar topics

1
by: Sporge | last post by:
Hi All Is there any way to decrease the polling interval that Oracle uses to determine if there are jobs pending in the job queue. It appears that it takes up to 5 seconds for a job to be...
0
by: Vijay Varadan | last post by:
We're using Enterprise Application Block June 2005 w/ Visual Studio 2003 .NET. We've configured our ASP.NET web service to run under a specific domain account using the instructions at...
1
by: Daniel Bass | last post by:
hey guys. overview --------- I'm designing a messaging system that works on the principle of late binding to the I/O objects, depending on the .Net class libraries present in the local folder....
2
by: Viet | last post by:
I have a couple of questions that hopefully someone could clarify for me. I have an app that uses the threading.timer to constantly poll a scanner to scan in documents. I understand that Async...
0
by: Viet | last post by:
I understand that Asynchronous delegates can be used to poll but most of the examples show the polling being done for a specified period of time. Are there any examples in VB.NET forms that show...
1
by: engwar | last post by:
Is anyone aware of any freely available software written in a .Net language for adding polling features to an existing website? I'm looking for just a polling component and not interested in...
1
by: kelvin.jones | last post by:
Hi guys, I have read several discussions on this group (and others) that talk about polling a server using ajax transactions and if it is possible to push to the client. The general consensus seems...
5
by: Mike | last post by:
Hi everyone, I would like to be able to send updates to my web page from the server. If I understood correctly, this is not possible to achieve in a web environment, unless some sort of polling...
13
by: LordHog | last post by:
Hello all, I have a little application that needs to poll a device (CAN communications) every 10 to 15 ms otherwise the hardware buffer might overflow when there are message burst on the bus. I...
3
by: Chris Mullins [MVP - C#] | last post by:
I'm sitting on the fence on this one, and wanted to get some other people's input. If you're a big B2B person, I would love to hear your feedback... I've got a SOA system. It's based on a...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.