Welcome to Bangladesh Microsoft Technology Community Sign in | Join | Help

Duplicate items are not supported by the "Sources" parameter (VS2005 IDE error)

Problem:
In one of my new project after generating some codes with .NetTiers, when I tried to compile the project in VS2005 IDE it started showing this error:

The item "Audit.cs" was specified more than once in the "Sources" parameter. Duplicate items are not supported by the "Sources" parameter. MyProject.Net.Entities

As you can guess there is not enough information or any direction on how to resolve this issue.


Solution
:
As usual started googling and found some hints that in the csproj file there might be same entry twice. I opened up MyProject.Net.Entities.csproj via Notepad I found the following nodes defined twice (in Nettiers Entities) (if you are not using Nettiers you might have only one item).

<Compile Include="Audit.cs">
<SubType>Code</SubType>
</Compile>
<Compile Include="AuditBase.generated.cs">
<DependentUpon>Audit.cs</DependentUpon>
<SubType>Code</SubType>
</Compile>
<Compile Include="IAudit.cs">
<DependentUpon>Audit.cs</DependentUpon>
<SubType>Code</SubType>
</Compile>

I deleted these nodes and made sure only one node exists for each item, and that solved the problem.

Hope this helps.

Published Tuesday, October 23, 2007 2:45 AM by Shahed

Comments

No Comments

Anonymous comments are disabled