Home » C# ProgrammingRSS

What is Designer for in .csproj?

When I open a solution which consists of bunch of projects, sometimes I just edited one project and rebuild, the IDE asks me to save a bunch of file I didn't edit...

With some investigation,  I found out that somehow those csproj got "<SubType>Designer</SubType>" added...

What is this tab for in the csproj? What is the reason this was added and why this was not there at the beginning?

Is there a documentation about all tabs in csproj?

Thanks.

 

7 Answers Found

 
 

Answer 2

Thanks for the links. However, after scanning thru them, I still think these answer my queries below,

What is this tag for in the csproj?

What is the reason this was added (i.e. What triggers <SubType>Designer</SubType> added to the csproj? )

and why this was not there at the beginning?

Can you help to elobarate more? Thanks.
 

Answer 3

Hi,

As I understand, the SDK document for the project SubType is very clear. Could you please clarify which part in this document you can't understand it? If you installed VS.NET 2005 in your PC, you can find project SubType sample codes in the default folder - "C:\Program Files\Visual Studio 2005 SDK\2007.02\VisualStudioIntegration\Archive\CS_Samples\ProjectSubtype\ProjectSubtype" provided in the SDK as your guide for much of the features you needed to implement. Besides, try to check out this blog about "VS 2005 Project Subtypes" for reference - http://weblogs.asp.net/rgillen/archive/2006/06/15/VS-2005-Project-Subtypes.aspx

Hope this helps,

Regards,

 

Answer 4

I am in exactly the same situation and don't think this thred answers the original question.

I use SVN for source control, when I get the solution from the repository and open it, VS tells me to reload some of the projects and on reload, the project file has changed. it has an extra line <Subtype>Designer</Subtype> and I do not want this line to automatically appear in my csproj file, what do I need to do?

 

Answer 5

I agree with Wood and sparkhi. 

The question isn't "What are SubTypes and how do you use them". 

The question is, "Why, when opening up a given .csproj, does this SubType block get inserted automatically by the IDE when it wasn't needed originally?"   What does this block do?  And why was it inserted by the IDE requiring a modification commit into source control?

FYI, this same problem exists in VS2008.
 

Answer 6

Has anyone resolved this?

We are experiencing the same thing in our development group now.  Sometimes it changes because the IDE ADDs these tags, other times it changes because the IDE REMOVES them.

Could it be related to a particular developer's IDE settings?  We have a team in Germany and a team in the US working on the same code base.  Some quick research shows that whenever a member of the German team commits a change to a csproj, the <SubType> flag is added.  When we get these files and build the projects in the US, the IDE removes these tags from the cproj file. 

It's rather annoying to see changes to files that are not legitimate and it adds complexity to our revision tree in source control.  So I would ask the same question as the OP: 

What triggers the insertion of this <SubType> block, why do some IDEs add it and others remove it, and is there a setting we can all set to make sure our environments are the same?

Thanks,

Josh

 

Answer 7

Surprise to see even after 2 years no one has explained a reason for it.

 

I got the same same "<SubType>Designer</SubType>" added in my code project automatically. and I am surprise too see that.. 

 

Has anyone get any answer yet..?

 

Thnx n Rgds

Nishant 

 
 
 

<< Previous      Next >>


Microsoft   |   Windows   |   Visual Studio   |   Follow us on Twitter