Thank you for getting back to us. Allow me to join the thread and help provide additional troubleshooting for this strange behavior in QuickBooks Desktop.
First, let's check if you can make it work by removing the worksheet protection within the Excel program. For the detailed steps, please visit the Microsoft support article below:
I also recommend creating a sample file and export payroll data to Excel to determine if the problem is company file related. If you're able to export successfully, we'll need to get back and run the Verify and Rebuild data feature to fix any data damage.
To verify data:
After following the steps above, you can proceed with resolving any data issues the Verify Data finds. Here are the steps:
For additional reference about the Verify/Rebuild process, I'm adding the article I recommend on this:
I look forward to serving you to the best of my ability so feel free to post your response regarding the troubleshooting results. The Community is always here to help.