S
Scott Meddows
How can I tell if my program is already running in memory? Code is
appreciated.
Thanks
appreciated.
Thanks
Scott Meddows said:How can I tell if my program is already running in memory? Code is
appreciated.
George Shubin said:'Check to see if a previous instance of this application is running already
(UBound(Diagnostics.Process.GetProcessesByName(Diagnostics.Process.GetCurren
tProcess.ProcessName)) > 0) Then
MessageBox.Show("Already running a copy of this program on your
system.", , MessageBoxButtons.OK, MessageBoxIcon.Information)
Return False
Exit Function
End If
--
------------------------------------------------------------------------
George Shubin Custom Software Development
dX Software Systems Database Applications
Ph: 503-981-6806 Fax: 503-982-0120
www.dxonline.com (e-mail address removed)
* "Scott Meddows said:Thanks. EXACTLY what I needed!
* "Scott Meddows said:How can I tell if my program is already running in memory? Code is
appreciated.
Herfried K. Wagner said:But won't work if there are 2 or more apps with the same name (but
different apps) running on the machine. I know, that's a rare case,
but it can happen for simple app names like "Calc" or something like
that.
* "Armin Zingler said:But you can start calc twice!
;->
* "CJ Taylor said:*Slaps Herfried in Head*
Was it really "necessary" to write your own Calc app? Cmon now. =)