MSBuild Error MSB3021

 

Unable to copy file "'<file>'" to file "'<file>'". '<error>'

The Copy task cannot copy the specified file.

To correct this error

  • Check to see if the target file is locked (in use) by another application. Be sure you have permission to read the source file and to write the target file to the target folder. If the destination file path is extremely long, you may need to copy to a different location.

See Also

Copy Task
MSBuild Tasks