Hi @Jack Wu
As far as I know, you may try the following Group Policy setting in a test machine.
Enable the Block signing into Office setting which is under User configuration > Administrative Templates > Microsoft Office 2016 > Miscellaneous.
Select the option you want in this setting.
More information, please refer to this article.
If an Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.