As an extension of the answer I provided for you in your previous question:
@( Echo @Echo %%CD%%
Echo @For /L %%%%G In (10 -1 0^) Do @MD Items%%%%G
) 1> "Folder Generator1.bat"
Or:
@(Echo @For /L %%%%G In (10 -1 0^) Do @MD Items%%%%G) 1> "Folder Generator1.bat"
The script will always work based on the current directory, if you haven't specifically changed it within your code. Please note however, that you cannot be sure what somebody's current directory is, when they run this command in their batch file, so should really offer them a chance to change it before creating multiple directories within it.
Additionally, if you wanted the current directory to always be that of the running batch file, you'd use CD /D "%~dp0"
:
@( Echo @CD /D "%%~dp0"
Echo @For /L %%%%G In (10 -1 0^) Do @MD Items%%%%G
) 1> "Folder Generator1.bat"
Or stipulate it in the MD
command:
@(Echo @For /L %%%%G In (10 -1 0^) Do @MD "%%~dp0Items%%%%G") 1> "Folder Generator1.bat"