Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- :: Check for administrative permissions
- >nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"
- if '%errorlevel%' NEQ '0' (
- echo Requesting administrative privileges...
- powershell -Command "Start-Process cmd -ArgumentList '/c %~s0' -Verb RunAs"
- exit /B
- )
- :: Change directory to Scrcpy installation folder
- cd "C:\Program Files\Scrcpy"
- :: Run scrcpy
- scrcpy
- pause
- :: Don’t forget to change "C:\Program Files\Scrcpy" to your Scrcpy folder path.
- :: And if you have already added the Scrcpy folder path to the system environment variables, you can remove the CD line.
Advertisement
Add Comment
Please, Sign In to add comment