If you're talking about service & application 'on a single, local pc', then, if the application creates a unique mutex, the service can check if the mutex is already in use or not... already in-use means the application is running. When the application ends, by fair means or foul, it closes and disposes of the mutex ...
That is but one way - do a google search for C# Single Instance Application and you'll likely come up with some code - this for example
Single instance C# application · GitHub[
^]