catch system shutdown event

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'm developing a windows service application using C#.NET and I need to catch
the system shutdown event to run service closing process. I override the
OnShutDown event but nothing happened when rebooting the system. I also need
to catch the same event in the service manager (winsows form application), I
find the event SystemEvents.SessionEnding but again nothing happened here.
I've tried these events using .NET 2002 and 2003 and under windowsXP
Professional and windows 2000 server.
any one know what's the problem with these events?
thanx...
 
Hi,

http://www.dotnet247.com/247reference/msgs/23/116468.aspx

Ken
-------------------
I'm developing a windows service application using C#.NET and I need to
catch
the system shutdown event to run service closing process. I override the
OnShutDown event but nothing happened when rebooting the system. I also need
to catch the same event in the service manager (winsows form application), I
find the event SystemEvents.SessionEnding but again nothing happened here.
I've tried these events using .NET 2002 and 2003 and under windowsXP
Professional and windows 2000 server.
any one know what's the problem with these events?
thanx...
 
Back
Top