In Visual Studio 2019 how can I remove unused usings on format document?
问题 In Visual Studio 2019 how can I remove unused usings on format document? I have found instructions for previous versions of Visual Studio (Go to Tools > Options > Text Editor > C# > Code Style > Formatting.). I don't see that in Visual Studio 2019. 回答1: In Visual Studio 2019 you can remove unused usings with the Code Cleanup command: And running code cleanup also formats the document. 回答2: CTRL + K + E Will sort and remove your unused usings. 回答3: You can assign both functions to Ctrl + K,