Originally Posted By: tfabris
My favorite way to check for admin privileges in a DOS batch file is this one


Still easier in PowerShell:

Code:
([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(
        [Security.Principal.WindowsBuiltInRole] "Administrator")


smile
_________________________
-- roger