I\'m using Visual Studio to try out Xamarin.Forms. I\'m trying to follow the guide: http://developer.xamarin.com/guides/cross-platform/xamarin-forms/xaml-for-xamarin-forms/getti
App.xaml
and MainPage.xaml
file of the class in which the issue is present.MSBuild:UpdateDesignTimeXaml
"I have met this problem. It's associated with the encoding of XAML files in VS. I'm using VS2015.
I solved this problem as follows:
Open the *.xaml file in the project and click Save button. (There will be applying the correct encoding in VS2015).
Then reopen the project and rebuild it. Now there are no errors.
A Clean and rebuild did the trick for me!
Right click *.xaml and click properties,and change "Custom Tool" value to "MSBuild:UpdateDesignTimeXaml", next change "Build Action" properties to "Embedded Resource", build project works.
Very simple solution that worked for me:
Now the InitializeComponent() function appears without red underline.
Hope this helps someone.
In my case the problem was the project path. The generated code file gets a name including the absolute path encoded to make it a valid filename. The path was "D:\Projekt C#\ProjectRootFolder\Project". The filename generated by the build tool was "Project.Droid.D_.Projekt_C_. Namespace etc." Moving the project to a path like "D:\project\ProjectRootFolder" helped in my case.