VS publishing error failed to copy file

Source: Internet
Author: User

My self-built website ASP. MVC4 has never been published since it was recently modified and written.

Error 15: The file easyui \ themes \ gray \ images \ Thumbs. db cannot be uploaded.
Copy to obj \ Release \ Package \ PackageTmp \ easyui \ themes \ gray \ images \ Thumbs. db. The file "easyui \ themes \ gray \ images \ Thumbs. db" cannot be found ". 0 0 MvcTender




Error 14: The easyui \ themes \ default \ images \ Thumbs. db file cannot be copied to obj \ Release \ Package \ PackageTmp \ easyui \ themes \ default \ images \ Thumbs. db. The file "easyui \ themes \ default \ images \ Thumbs. db" cannot be found ". 0 0 MvcTender


I have not moved these files. this is because of the habit of packaging local backup for the entire project after the partition time. SVN also supports backup. double insurance. compare the items that were restored half a month ago. mvcTender. previous projects in csproj also reference easyui \ themes \ gray \ images \ Thumbs. db but no error is reported. trying to publish is successful. other parameters cannot be seen. there is no way to use the online method.


The following is an excerpt from a netizen

========================================================== ===

Http://guangquanzhu.blog.163.com/blog/static/112084455201331695143640/

In the past few days, when I modified some of the functions of the Group Buying navigation website in asp.net, I encountered an error:

Failed to copy the file upfile \ team \ 2013 \ 0328 \ 20130328112637296.jpg to obj \ Debug \ Package \ PackageTmp \ upfile \ team \ 2013 \ 0328 \ 20130328112637296.jpg. The file "upfile \ team \ 2013 \ 0328 \ 20130328112637296.jpg" cannot be found

Note: This image file was uploaded during testing. After a long time, it will take up more images on the hard disk. Therefore, after they are all deleted, the above situation will occur when the website is released.

I have studied the following:

Method 1: the stupid method is to temporarily put the missing images in the corresponding folder according to the error prompt, so that the re-release is successful, however, this is troublesome. Second, these images are junk images for the current website. They are useless, waste hard disk space, and increase server pressure.

Method 2: in fact, this error occurs during release because the "<Content Include>" parameter in the. csproj project file has already stored these file paths (as shown below ):

 

Some files are deleted later, but the parameter record in. csproj is still in progress. Therefore, when the file is released, the following error occurs ...... Copy ......" . So someone on the Internet gave a solution: delete it. the corresponding <Content Include> line in the csproj file is feasible after testing, but this is still troublesome. If a large number of image files are stored in multiple directories (for example, a folder is generated every day ), manual deletion is cumbersome.

My method 3, based on the previous method is cumbersome, I thought of a very stupid method, first put the entire directory of upfile in solution Resource Manager "excluded from the project ", then, "regenerate the solution", release the solution, and copy the upfile directory to the released website directory. The test is feasible.

 
 

Of course, my method is just a gossip. In the final analysis, we should not generate garbage files. For example, after deleting a database record, we should not forget to delete the corresponding image files together. I'm Zhu guangquan. Thank you for visiting.

========================================================== ===

Http://blog.csdn.net/lisliefor/article/details/2482653

[Problem] When VS 2003 is used to compile the solution, the following error occurs: "temporary files cannot be copied to the output directory" and "*. dll files cannot be copied to the running directory. The process cannot access the file because another program is using this file ". The class library files added to the solution cannot be programmed as DLL and output to the "/bin" directory of the site.

[Try]

1. This is a BUG of 2003, the official solution is: http://msdn.microsoft.com/zh-cn/library/tta90aft (VS.80). aspx, but according to its practice, it cannot solve the problem.

2. Run the "net stop w3svc" command to compile the program. The problem persists.

3. Make sure that VS does not open "Object Browser" and other web applications occupy these DLL files.

4. Compile the program after restarting the computer.

[Solve the problem]

A friend mentioned that his use of Kingsoft drug overlord caused this problem. Later, he shut down Kingsoft's anti-virus software and can compile it. Does my computer use anti-virus software of red umbrella?

Sure enough, after disable, You can compile normally. Maybe some friends are having a headache for this problem. I hope this article will solve your problem.



I directly removed the "<Content Include>" parameter from the. csproj project file.

Because the Thumbs. db;. db file is only the cache file does not matter.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.