Custom file sorting in VS2010 Solution Explorer

2k Views Asked by At

Is there any way to force Solution Explorer in Visual Studio 2010 to sort files alphabetically but in order *.h, *.inl and *.cpp?

I want to have

Dummy.h
Dummy.inl
Dummy.cpp
Emmy.h
Emmy.cpp
Grammy.h
Grammy.cpp

instead of

Dummy.cpp
Dummy.h
Dummy.inl
Emmy.cpp
Emmy.h
Grammy.cpp
Grammy.h
1

There are 1 best solutions below

0
On BEST ANSWER

No, there is no such feature built in.

I don't know of any extension or add-in that supports this, either, but I imagine that you could create one. Get started with the Visual Studio SDK, or browse the Visual Studio Gallery for something that serves a similar purpose.

However, the Solution Explorer does support grouping related files (such as headers, resources, and code files) into virtual folders. Turn that feature on by deselecting the second button to the left at the top of the Solution Explorer window labeled "Show All Files".