我正在尝试制作一个批处理脚本Hackoo's回答这问题是将其重新用于复制文件而不是打开文件。这可以使用类似的结构来完成吗?以下是我对脚本的修改:
@echo off
Title Drag and drop a font to install.
Mode con cols=60 lines=3
IF [%1] EQU [] Goto:Error
CD /D "%~1">nul 2>&1 && Goto:Explorer_Folder || Goto :OpenFile
Exit /b
:OpenFile <File>
COPY "Drag and drop your font here..." "C:\Program Files\Common Files\Adobe\Fonts" "%~1"
Exit /b
:Explorer_Folder <Folder>
Explorer "%~1"
Exit /b
:Error
Color 0C & echo(
ECHO You must drag and drop a font into this tool!
Timeout /T 5 /NoBreak >nul
Exit /b