This project is read-only.

Cannot update an AssemblyInfo.cs file if it has duplicate assembly attributes


If an AssemblyInfo.cs or .vb file contains mulltiple duplicate assembly attributes - the process fails with the following error:
Update Assembly Info files - An item with the same key has already been added.
  1. add Web Resources into your project
  2. Add the required WebResource assembly attribute into the AssemblyInfo.cs file - one for each web resource (the resource designer may add these in for you)
    [assembly: WebResource("File1.gif", "image/gif")]
    [assembly: WebResource("File2.gif", "image/gif")]
    [assembly: WebResource("File3.bmp", "image/bmp")]
  3. Create a build definition for the project
  4. Add MetaData collection values - enable
  5. Trigger a build
    Error occurs: An item with the same key has already been added.
    I cannot debug this at this moment since I don't have TFS installed locally, so I'm not sure where the problem is... but there is only one Dictionary.Add(..), but this doesn;t seem to be the culprit.