I am writing a service for Vista where I need to delay system shutdown in
the case it is in the middle of a critical operation.
I am using the new Vista "Preshutdown" notification.
I have configured the preshutdown timeout to a large value (in the order of
hours) using the "ChangeServiceConfig2" API.
In the HandlerEX function, I have a case for the Preshutdown control.
I do get the preshutdown notification and respond by calling
"SetServiceStatus(SERVICE_STOP_PENDING)". However, the service gets killed
within 30s and the system shutdown continues.
If anyone has used/tested this before, please help!