1.Error143Could not copy "obj\Debug\LibrarySystem.exe" to "bin\Debug\LibrarySystem.exe". Exceeded retry count of 10. Failed.
2.Error144Unable to copy file "obj\Debug\LibrarySystem.exe" to "bin\Debug\LibrarySystem.exe". The process cannot access the file 'bin\Debug\LibrarySystem.exe' because it is being used by another process.
I have tried with add the following in the build event.
if exist "$(TargetPath).locked" del "$(TargetPath).locked"
if not exist "$(TargetPath).locked" move "$(TargetPath)" "$(TargetPath).locked"
it worked for me once. but next time same error occur. how can solve this problem.
Rushi DaxiniPosted Oct 22, 2014, 7:25 AM
**Temporary Solution is...
-> Go to Task Manager(Ctrl+Alt+Esc).
-> Go to Processes tab and find "YourProjectName.exe".
-> End Process it.
**Permanent Solution is...
-> You have to close your application through coding.
-> Here is the code...
System.Windows.Forms.Application.Exit();
-> You have to put this code in to the form closing event in all form.
Example:
private void frm_menu_FormClosing(object sender, FormClosingEventArgs e)
{
System.Windows.Forms.Application.Exit();
}