Q: Some of the things we do in our logon scripts require the user to be a local administrator. How can the script tell if the user is a local administrator or not, using PowerShell 7.
A: Easy using PowerShell 7 and the LocalAccounts module
Local Users and Groups
The simple answer is of course, easily. And since you ask, with PowerShell 7! ...