FC2ブログ
Welcome to my blog

ラディア

ラディア



@ECHO OFF

REM ===================================================
REM 参考URL:http://d.hatena.ne.jp/simpraight/20070719/1184817382
REM http://www.atmarkit.co.jp/fwin2k/win2ktips/899uacpromo/uacpromo.html
REM ===================================================

PUSHD %~dp0
CLS
:
: 管理者権限で実行するスクリプトテンプレ
:
IF "%~1" == "/a" GOTO IS_ADMIN


NET USER %USERNAME% | FINDSTR "\*Administrators" >NUL
IF %ERRORLEVEL% == 0 GOTO IS_ADMIN

RUNAS /user:administrator "cmd /c \"CALL \"%~0\" /a\""
GOTO END

:IS_ADMIN
REM ===================================================
REM フォルダ名とかは、各自環境に合わせて変更してね☆ミ

START "C:\Program Files\CPU-Z\cpuz.exe"
START "C:\Program Files\Core Temp\Core Temp.exe"
START "C:\Program Files\GPU-Z\GPU-Z.0.5.5.exe"
START "C:\Program Files\HWMonitor\HWMonitor.exe"

REM ===================================================

:END
EXIT

Posted by

Comments 0

There are no comments yet.

Leave a reply