added the option to change the format to copy file