Xamarin WebView - No Intellisense at Razor

I am trying to use xamarin webView where you can use a razor as a user interface. But intellisense for C # code is not working.

Is this a known mistake or am I missing something? Do I need to configure it in the webConfig file?

The code works and builds, but when I need a model in a razor, intellisense will not work:

@model TestProject.Models.Model1 <html> <head> <title>testProject</title> </head> <body> @Model.Text </body> </html> 

Where I write @model and @model , it just says: "Cannot resolve character ..."

What to do?

+3
c # razor xamarin
Jan 14 '15 at 21:19
source share
2 answers

Close all instances of Visual Studio.

Go into your "(Visual Studio installation path) \ Common7 \ IDE \ Extensions \ Xamarin \ Xamarin \ 3.9.483.0 \" And rename the three files: System.Web.Razor.dll, System.Web.WebPages.dll and System.Web .WebPages.Deployment.dll in System.Web.Razor.bad, System.Web.WebPages.bad and System.Web.WebPages.Deployment.bad.

Find your registry using the registry editor and remove the "RazorTemplatePreprocessor" key.

Delete the custom settings files for your solution: (Solution Name) .suo

When you start Visual Studio, you will get your intellisense razor again!

+10
Apr 07 2018-01-15T00:
source share

We had this problem, and we found a solution on Michael Ridland's blog as a project called MVCPolyfils. The post and .git repository can be found here: https://github.com/rid00z/MVCPolyFils

We added it and updated the links in our .cshtml headers and it all works now - such a relief!

+1
May 20 '15 at 10:29
source share



All Articles