Relative Content

Tag Archive for batch-file

Move file and directory another path

@echo off setlocal enabledelayedexpansion rem Source directory set “sourceDir=C:pathtosourcedirectory” rem Destination directory set “destDir=C:pathtodestinationdirectory” :loop rem Change to the source directory cd /d “%sourceDir%” rem Loop through all files in the source directory for %%f in (*) do ( rem Get the file name without extension set “fileName=%%~nf” rem Check if the folder with the […]

Create batch files based on file names

I have a large amount of folders with files which I want to create batch files for. Batch files for the individual files and 1 batch file based on all files in 1 folder.

Batch Script start Command Ignoring Quotation Marks

I am attempting to make a script in batch (with the help of chatGPT for syntax) to compile C++ programs for me using the VS2022 compiler, and so far my batch script can successfully locate and compile .cpp files, but can’t run them for some reason.

how to convert or get persian date in a batchfile

I use of this code for change date format to yyyymmdd and its work completly true
now my problem is I want to change it to persian date (Shamsi calendar) or get persian date directly with my batch file
i use this code