C#: Check if an application is already running

This is the snippet code to check if application running or not in C#

using System.Diagnostics;
bool IsApplicationAlreadyRunning(string processName)
{
Process[] processes = Process.GetProcessesByName(processName);
if (processes.Length >= 1)
return true;
else
return false;
}


By
NOTE : – If You have Found this post Helpful, I will appreciate if you can Share it on Facebook, Twitter and Other Social Media Sites. Thanks =)

Popular posts from this blog

Example to disable save as certain file type in SSRS Report Viewer

Phone book application example - Java

Modal Popup Message Box ASP.NEt C# Example