IF you are using the System.IO.File.Copy() function, you can pass in a 3rd
parameter (besides the source and destination strings) which is a boolean
value. If this is set to true it will overwrite the destination file. As
for renaming, you would probably have to check for the existance of the file
with code and then go from there.
ex.
using System.IO;
void main()
{
string strSource = "y:\\apath\\afile";
string strTarget = "x:\\apath\\afile";
if ( File.Exists( strTarget ) )
{
strTarget = strTarget + ".new";
}
File.Copy( strSource, strTarget, true );
}
Hope this helps
Carlson Q