I was thinking to add some code in the .csproj file in the following tag, that would automatically clean the solution before a build attempt:
</ProjectExtensions>
<Target Name="BeforeBuild">
// Clean the project <------
</Target>
<Target Name="AfterBuild">
</Target>
</Project>
any ideas on how to achieve this?