I have finished a small Windows 10 app in C# and XAML and now I want to do a "Release" build of the app so that I can create app package.
The problem is: VS 2017 cannot create a release build of the app.
Please see the error message which VS give out after trying to release-build for around 20 mins.
I'm using Syncfusion PDF Viewer control in the app & hence have added reference to "Syncfusion Controls for UWP XAML".
I have tried un-checking the "Compile with .NET Native tool chain" in properties page. It works and I can do a release-build, BUT the Windows App Cert Kit "fails" my app.
Another information which I would like to add is: even if I do a File -> New UWP Project and try to do a release build of that - it still does not work.
I've also read the issue here, but it's does not seem relevant to my project. e.g., I am not referencing a winmd type.
What could be wrong?
Using the hammer approach, I deleted both the "obj" and "bin" folders (because the size didn't look right and anyways this is a demo project and I have backup)
After deleting, I set to release and build - and it worked!
Good thing, but it took 40 mins. Then after the first release-build, I changed some xaml and added some code (added button which show "Hello" dialog) and tried to build again. It failed.
Then I deleted bin and obj folders and then it worked again. But combined size of both folders is now 3.92 GB.
So everytime I need to do a release-build, I have to delete bin & obj folders and wait for appx 35~45 mins.
I will now repair VS 2017 as @Marian suggested and will let you know what happens. I do not know if this is an answer or it's rather a work-around.