Question

I'm looking to move .txt files from a folder containing many .txt files.

But only .txt files that start with string 'settlement-id' or contains 'settlement-id'.

Preferably a .bat file.

Was it helpful?

Solution

A way to do it :

@echo off
for /f "delims=" %%a in ('dir *.txt /b/a-d ^| find /i "settlement-id") do copy "%%a" "YOUR_PATH"
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top