Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not find file 'obj\Debug\OldProjectName.csproj.FileListAbsolute.txt

I'm trying to publish project (tools vs2010), but cannot all the time getting the error below. I paste to my projects files from another project and then I changed namespace (OldProjectName) to the parent project (NewProjectName). But it still getting information from somewhere about old project.

I cleaned solution, builded, rebuilded. Closed and reopened again and all the time the same error.

I'm able to build project but publish it.

Any ideas what can cause the problem?

Error 1 Copying file obj\Debug\OldProjectName.csproj.FileListAbsolute.txt to obj\Debug\Package\PackageTmp\obj\Debug\OldProjectName.csproj.FileListAbsolute.txt failed. Could not find file 'obj\Debug\OldProjectName.csproj.FileListAbsolute.txt'. 0 0 NewProjectName

like image 720
Eugene Avatar asked Mar 18 '11 01:03

Eugene


9 Answers

  1. Open your .csproj file in notepad

  2. Find "obj\Debug\OldProjectName.csproj.FileListAbsolute.txt"

  3. Remove that line and save it
  4. Open your project and try to publish it and this time you will be succeeded.

Note: if you are getting any more file like .pdb remove that as well.
Hope it will help you

like image 153
Ali Adravi Avatar answered Oct 03 '22 01:10

Ali Adravi


Make sure the obj folder is not read only, if so change read only property of this folder to false. this worked for me.

like image 27
Sanooj VS Avatar answered Oct 03 '22 00:10

Sanooj VS


Check the permissions to the folder obj\Debug\ if you give it write permissions, the error would go away.

like image 33
Ajay Avatar answered Oct 02 '22 23:10

Ajay


Check if the folders "bin" and "obj" are checked-in to source control, if so delete those two folders in source control. There is no need to check-in these two folders to source folders. Also make sure that these folders "obj" and "bin" are deleted from your hard disk, they will be created again after a build.

Hope this will fix your issue.

like image 32
Bharat Avatar answered Oct 03 '22 00:10

Bharat


It is your responsibility to make copies so you can go back to one.

Open your project file (vb/cs)proj with a notepad, and search for the missing files.

In my case I got this error when I tried to publish the project and certain files were not found.

Each publish attempt I got another file name, after checking that the file actually didn't exist in the project, I removed it from the project file, manually.

Then publish succeeded.

like image 25
Isaac Avatar answered Oct 03 '22 00:10

Isaac


Delete the obj folder and build again.

Ref: http://forums.asp.net/t/1402005.aspx

like image 27
Doc Avatar answered Oct 03 '22 00:10

Doc


Like many others these files were read only and needed to be deleted or actually able to be overwritten by VS. However, as may be the case for many others, the problem was because these files were checked in to source control. Your bin and obj folders should not be in source control. Mark them for delete and submit the changelist.

One exception to the rule is for the bin folder could be dll files that are not .Net compatible. Such as a C/C++ dll that you are using through a .Net wrapper dll. I mark them as content so that they get published and check them into source control.

like image 42
Mike Grimm Avatar answered Oct 03 '22 01:10

Mike Grimm


I too had this problem. I resolved this by deleting files inside project bin folder (.dll and .pdb) and closed and re-opened VS .

like image 27
Boopathy Avatar answered Oct 03 '22 01:10

Boopathy


The file named FileListAbsolute.txt was deleted from the folder obj/debug. Visual Studio can automatically recreate the file and others in the obj/debug for you. For VS to recreate it, set the configuration of the solution and the project to debug mode. Then rebuild your solution.

To change the configuration mode to debug, from the solution explorer, right-click on the solution name and select Properties.

Select Configuration under Configuration Properties. Then select Debug from the dropdown list. Click Apply and OK. Ensure that in Configuration Manager, the configuration mode is also a debug mode.

Then rebuild your solution.

like image 29
Felix Avatar answered Oct 03 '22 01:10

Felix