Visual Studio : hotkey/way to automatically sort functions in .h to be consistent with .cpp
I want to make order of functions in header .h to be consistent with the order of functions in source file .cpp . Example B.h class B{ void f2(); //<--- wrong order void f1(); }; B.cpp #include "B.h" void B::f1(){} void B::f2(){} Expected Result (B.h) class B{ void f1(); //<---- nice void f2(); }; Question Primary Question: Is there any (semi) automatic way to do ( .cpp -> .h ) in Visual Studio? Hotkey? Script? Plugin? Visual AssistX / Resharper? There is a similar question but it asks the opposite way (it has no solution). Secondary question: How to do the opposite way (semi) automatically? (