The school entrepreneurship competition requires multiple entrepreneurial projects. At this time, more than 100 files are created, and corresponding folders need to be created and placed in a folder with the same file name.
@echo off
setlocal enabledelayedexpansion
for %%a in (.pptx) do (
set "file=%%~na"
md "!file!"
move "!file:~,8!" "!file!\"
)
pause
Use the loop to determine the condition is all pptx files and create a folder corresponding to the file to cut and paste