bat文件调用Uipath流程
2020-11-19 本文已影响0人
万疆璃火
>>>>bat文件设置启动密码
@echo off
:loop
cls
set/p x=请输入密码:
if "%x%"=="12345" goto m
goto loop
:m
@echo off
echo 下载启动
pause
如果bat文件启动时发现中文乱码,则需要另存为,并且选择编码格式
image.png
>>>>设置bat文件启动时密码显示为密文
@echo off
:loop
cls
set "psCommand=powershell -Command "$pword = read-host '请输入密码' -AsSecureString ; ^
$BSTR=[System.Runtime.InteropServices.Marshal]::SecureStringToBSTR($pword); ^
[System.Runtime.InteropServices.Marshal]::PtrToStringAuto($BSTR)""
for /f "usebackq delims=" %%p in (`%psCommand%`) do set password=%%p
if "%password%"=="12345" goto m
goto loop
:m
@echo off
echo启动
pause
"C:\Users\AppData\Local\UiPath\app-19.10.2\UiRobot.exe"execute--file "D:\uipath\Main.xaml" --input"{'str_run':'2'}"