MVC控制器出现问题 [英] Problem with MVC Controller

查看:80
本文介绍了MVC控制器出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经对控制器中的代码进行了更改,但是似乎并没有在网站上找到.如果我更改了拾取的其中一个视图aspx页面而不是控制器的更改.

我正在使用VS 2010
MVC 1
VS2010托管的本地计算机

我试图改变的事情是
-修改方法以返回不同的字符串
-添加一个方法,然后尝试调用它.

任何建议将不胜感激.

谢谢

I''ve made a change to the code in my controller but it doesn''t seem to be picking up on the website. If I make a change to one of the view aspx pages that is picked up but not the controllers.

I''m using VS 2010
MVC 1
local hosted by VS2010

The things I''ve tried to change are
- modify a method to return a different string
- add a method and try and call that.

Any suggestion would be appreciated.

Thanks

推荐答案

您是否在重新部署之前重建了项目?
Did you rebuild the project before redeploying?


我确实进行了重新编译.看起来VS已使其成为一个Web项目,而不是MVC项目.所以我需要更改它
I did recompile. It looks like VS has made it a web project instead of an MVC project. so I need to change it



很多时候,我也变得一样.那时我只是删除发布文件夹并重做发布.
Hi,
Many of the times I am also getting the same. At that time i just delete the publishing folder and redo the publishing.


这篇关于MVC控制器出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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