[Suggestion] Prevent computer from sleeping while creating backup
My Windows 10 computer sets idle times to sleep, e.g., 5 minutes. However, it takes 30 minutes for backing up my computer by Hard Disk Manager 16 Basic. If an idle time during the backup is over the time to sleep, Win 10 goes to sleep and stops the backup process. I know there is a solution to prevent Win 10 from sleeping while running a long time process. That's call this Windows API before executing a long time function:
SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED);
https://msdn.microsoft.com/en-us/lib...(v=vs.85).aspx
Could Hard Disk Manager developers fix this problem by using this API?
Re: [Suggestion] Prevent computer from sleeping while creating backup
Quote:
Originally Posted by
myh
My Windows 10 computer sets idle times to sleep, e.g., 5 minutes. However, it takes 30 minutes for backing up my computer by Hard Disk Manager 16 Basic. If an idle time during the backup is over the time to sleep, Win 10 goes to sleep and stops the backup process. I know there is a solution to prevent Win 10 from sleeping while running a long time process. That's call this Windows API before executing a long time function:
SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED);
https://msdn.microsoft.com/en-us/lib...(v=vs.85).aspx
Could Hard Disk Manager developers fix this problem by using this API?
This is really nothing to do with Back-up.
All you have to do is change the setting to not sleep ever, then change it back if you want after the back-up
Re: [Suggestion] Prevent computer from sleeping while creating backup
Quote:
Originally Posted by
mettallium
This is really nothing to do with Back-up.
All you have to do is change the setting to not sleep ever, then change it back if you want after the back-up
I have known this workaround. But it's a bit inconvenient.
I have some experiences to write programs and used SetThreadExecutionState to solve the sleep problem, and I think it is not too difficult to use it.