简体   繁体   中英

The process cannot be accessed because it's being used by another process

Allow me to paint the picture if you will. All the posts I have read regarding this issue the only thing i haven't found is the solution/cause to the problem. Why hasn't MS fixed this?

I work on a solution at home and at work and we have Team Foundation Server(TFS) setup. When at home I have to VPN in. I have VS 2010 SP1, Win XP SP3 at work and Win 7 64 bit at home w/ SQL Server 2008 R2 Developer.

For years now I have worked with no issues while debugging what so ever from either location.

Just recently we published the application to the server from the work location (Win XP SP3 Pro) and only since then I get this 'The process cannot access the file because it is being used by another process" error.

I do not have any problems working from home. (WIn 7 64 bit machine) and I have not published from home at all either for what it's worth.

When at work I have to restart VS or keep task manager open and endprocess for the process of the app named appname_vshost.exe (or simular) 2-3 times before debug will run again smoothly. If I don't VS IDE is very painfully slow to respond.

I have totally deleted the Project files locally and retrieved them fresh from the TFS. Everything runs fine until I edit something in the solution (project) and it starts all over again.

Anyone know of any solutions that I may not have found as yet? I think having to creat a "work around" is a bandaid and not a solition any ideas?

Assuming you mean when you compile....

I wasted days upon days upon days on this...until I come across this:

http://connect.microsoft.com/VisualStudio/feedback/details/700166/compiler-locks-generated-exe-file-when-application-experience-service-is-turned-off

It is essentially due to the Application Experience services being turned off.

Go into your Services list (Control Panel > Administrative Tools > Services), ensure it is set to Automatic.

Not had the problem since.

尝试使用Unlocker确定哪个文件确切地被哪个进程锁定,您可以在文件夹级别运行它,这样您就可以在整个项目编制器上发生错误时尝试它。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM