Delete obj and bin folders
To proceed, right-click in Solution Explorer and select Delete bin and obj folders
In case of a .net core project, the bin & obj folders are deleted but restored in a few seconds because the project system is watching those files through project.assets.json, if it is deleted, the packages are restored, which means that your solution will be rebuilt. To prevent this, you should disable nuget packages auto restoring