I am having some files names are as follows:
Delphi100_1.txt
..
..
Delphi100_9.txt
Delphi101_1.txt
..
..
Delphi101_9.txt
Delphi109_1.txt
..
..
Delphi109_9.txt
I need to rename as *_?.txt
as *_.txt
. At the time renaming existing files will be replaced without prompt. After processing there will be only files with the following names :
Delphi100.txt
..
Delphi109.txt
existing function RenameFile(const OldFileName, NewFileName: string): Boolean;
can not replace if file with same name already exists.
How this can be done?