Reputation: 1837
I have one Windows Service in WCF running under admin user , this is not the logged user.
When the User will to stop de service, I want to show an Windows Form with a alert.
This is possible?
Upvotes: 0
Views: 78
Reputation: 355
The issue you will encounter I think is to do with Windows sessions and which user is currently logged in. Popping a window might well work but won't necessarily show unless you are logged in as the same user that the service is running in the context of.
Another solution may be to create a system tray application that monitors the state of the service and communicates through windows messages or another mechanism. You could certainly have a timer there that confirms that the service in question is still running every X seconds, but that will be somewhat resource intensive.
Are there other mechanisms that would work for the communication such as email?
Upvotes: 1