I run my app from a sub main and this is how I was shown to do it.
Imports System.Threading
Private m As Mutex
Sub Main()
Dim first As Boolean
m = New Mutex(True, "Your App Name Here", first)
If Not (first) Then
MessageBox.Show("The Application is already running.")
AppRunning()
Exit Sub
End If
Private Sub AppRunning()
Application.Exit()
End Sub
System wide meaning on a single computer... Yes. Network wide of web
wide... I don't think so.
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.