Hi, @Martha Campbell
If you haven't tried it yet, first, go to Settings > System > Power & battery > Screen, sleep & hibernate timeouts.
Set "Make my device sleep after" to "Never" while plugged in. You can change it back after the scan finishes.
To help narrow this down:
- Are you running the Quick scan in Windows Security/Microsoft Defender, or another antivirus?
- Does the PC go to sleep while plugged in, or only when running on battery?
Click "Add comment" to let me know.
Thanks!