MVC 3至5 MVC剃刀移民问题的语法 [英] mvc 3 to mvc 5 migration razor syntax issue

查看:100
本文介绍了MVC 3至5 MVC剃刀移民问题的语法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们用于升级换代的官方教程,继后,我们得到了没有生成错误,运行某些功能不工作了。我们看到,一些剃刀语法被显示为红色的语法错误/某些结束标记丢失。可能是什么原因

We used official tutorial for upgradation, after following, we got no build errors, after running some functionalities are not working. We saw that some razor syntax were showing red as syntax error/some closing tag missing. what may be the reason

编辑:
这些错误的图像下面

http://p.lui.li/img-40102_1_p-r-full.png

而另一个样品

http://p.lui.li/img-40102_2_p-r-full.png

还有这样的错误div标签未关闭。
所有这些codeS是在MVC3做工精细

there are still errors like div tag is not closed. All these codes were working fine in mvc3

推荐答案

我有同样的问题,昨天,当我将我的老3.0的项目MVC 4在2013年ViewBag和东西也是目前情况下没有找到,即使它在浏览器做工精细

I have same problem yesterday when I convert my old 3.0 project to MVC 4. in 2013 ViewBag and something also not found in current context even it's work fine in browser.

请用相同的命名空间的新的应用程序,并复制粘贴仔细东西。做这个项目后,将工作就像一个魅力。

Make a new app with same namespace and copy paste the stuff carefully. After doing this your project will work like a charm.

这篇关于MVC 3至5 MVC剃刀移民问题的语法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆