When you try to build setup project, you will get an error
Unable to build project output group ‘Content Files from PROJECTNAME(Active)’
Note : where PROJECTNAME is replaced by your current solution
CAUTION :
This error refers to items that are included in the web-project but missing on disk.
Solution :
If you have come to this article after reading many other blogs and sites you must be definitely knowing that this error occurs only when any class file or reference file is missing physically from your current project.
Microsoft Official support says : To resolve this behavior, you can replace any missing dependency files, or you can remove the file that requires them if the project does not require that file. but it makes confused that if any reference is missing that project would not run properly but it is running.
Normally, this error is easily fixed by simply adding or removing references, but in your solution you don’t see any file missing. and make matters worse, when right-clicking on the project in Visual Studio and select “Rebuild”, it works every second time with no errors and every time when setup project runs it gives error : Unable to build project output group ‘Content Files from PROJECTNAME(Active)’
Now perform following steps :
- From Solution Explorer Click on Show All Files (refer the image)
- You will find files that/those are marked with a yellow triangle (indicating that they are missing)
- just remove the reference if it’s not necessary or add dll to project if you need that file to run the project.
What if I don’t get any file with yellow triangle marked??
- Well it looks like you have added a reference which is not relevant to your project. What I mean is your project has unnecessary reference.
- First of all copy your bin folder once for backup.
- Now Remove one by one reference from project
- Compile it
- if compilation gives error and that reference is needed just add it back to project
- if compilation doesn’t give any error, you don’t need that dll file. You might have copied your previous project and start working in hurry (!! 🙂 )
- Also exclude unnecessary files from project.
Now Try to build your setup project. Hope you have find and fixed error from above steps so you are able to create deployment package of your solution.
Nice Post !! It will help us.