batch file run, del, copy

clint walker February 10, 2009 at 14:14:12
Specs: Windows Vista
I have this batch file that runs a file program that adds to a csv file and renames it. Then I want to delete the old file and move the new file to a dif folder.

Here is what I have, the program runs and manipulates the file but the delete and copy don't run.

@echo off

cd c:\Program Files\KnoblochSoft\FileManipulator


FileManipulator.exe "Borger Time.CSV" "Borger Time Out.CSV" b 2

del /s C:\payroll Transfer\borger_time.csv

COPY /b C:\Users\clint.DISCO\AppData\Local\VirtualStore\Program Files\KnoblochSoft\FileManipulator\Borger Time Out.csv C:\Program Files\Sage Software\Peachtree\Payroll Transfer\Borger Time Out.csv


See More: batch file run, del, copy

Report •

February 10, 2009 at 15:03:28
Hi Clint,

The del command is referring to another file, borger_time.csv which is not the one you've just created (it has an underscore instead of a space.)

The copy command doesn't work because when you have spaces in your filenames you must enclose them in quotes.

del /s "C:\payroll Transfer\borger time.csv"

By the way, that's a different directory name too!

COPY /b "C:\Users\clint.DISCO\AppData\Local\VirtualStore\Program Files\KnoblochSoft\FileManipulator\Borger Time Out.csv" "C:\Program Files\Sage Software\Peachtree\Payroll Transfer\Borger Time Out.csv"

I hope that helps.
"The Real" Klint

Report •
Related Solutions

Ask Question