Removing all unused references from a project in Visual Studio projects

前端 未结 14 2064
北荒
北荒 2020-11-29 16:41

I just wondered if it possible within various Visual Studio versions to automatically remove all references from a project that were never been used?

In your answer,

14条回答
  •  执笔经年
    2020-11-29 17:08

    Using DevExpress, I follow these instructions:

    1. In VS, go to DevExpress - Editor - Code Cleanup. Under Rules, check 'Remove unused namespace references'. Click OK.
    2. Right-click on the solution, and choose 'Code Cleanup'. The cleanup runs for a few minutes, and finishes.
    3. Build your application

提交回复
热议问题