From inside a batch file, I would like to test whether I\'m running with Administrator/elevated privileges.
The username doesn\'t change when \"Run as Administrator\
Works for Win7 Enterprise and Win10 Enterprise
@if DEFINED SESSIONNAME ( @echo. @echo You must right click to "Run as administrator" @echo Try again @echo. @pause @goto :EOF )