Create a file corresponding folder and move the corresponding folder

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
Create a file corresponding folder and move the corresponding folder

Guess you like

Origin blog.51cto.com/yangeinstein/2547321