@echo off goto check_Permissions :check_Permissions SET "C:\Users\BDAS\Desktop\check_admin=%~dp0"&SET "check_admin=%~dpf0" net session >nul 2>nul & if errorlevel 1 check_admin "%~0" %* if %errorLevel% == 0 ( echo Success: Administrative permissions confirmed. > res_txt.txt ) else ( echo Failure: Current permissions inadequate. > res_txt.txt ) pause
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)