IfMember Topics | Previous

IfMember Example

These lines of code illustrate the use of IfMember with IF ERRORLEVEL in a batch file:

ifmember Administrators

if not errorlevel 1 exit

REM the rest of this batch file will only be run if the user is a member of the Administrators group.