难道ASP.NET MVC使用常规的工具箱控件? [英] Does ASP.NET MVC use the regular toolbox controls?

查看:178
本文介绍了难道ASP.NET MVC使用常规的工具箱控件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在ASP.NET MVC中,我用常规控制从工具箱,并为它们分配数据就像我的WebForms做?我可以使用GridView控件,例如?

In ASP.NET MVC, do I use the "regular" controls from the toolbox and assign data to them like I did with webforms? Can I use the gridview, for example?

感谢您。

编辑:答案似乎是否定的。所以,你用什么?有没有在Visual Studio中的拖放控制,如Web窗体控件?

The answer appears to be no. So what do you use? Are there any drag and drop controls in Visual Studio like the webform controls?

推荐答案

在大多数情况下,使用MVC的肯定不是拖/放的事。没有自动布线数据绑定控件水平无论是。 MVC的结构中的目的是为了给在标记更直接的控制。有迹象表明,可以呈现表单控件可以使用一些辅助方法。 MVC是一个非常不同的发展模式的服务器端。注意,你可以用MVC结合ASP.Net成一个混合的项目。

For the most part, use of MVC is explicitly not a drag/drop affair. There isn't a level of auto-wiring data-bound controls either. The purpose within MVC's structure is to give more direct control over the markup. There are some helper methods that can be used with rendering Form controls. MVC is a very different development model server-side. NOTE, you can combine ASP.Net with MVC into a hybrid project.

我建议你需要非常舒服HMTL标记,以及如何HTTP + HTML沟通,以成功实现一个MVC项目工程。 JavaScript的使用也是非常明确的。 MVC是非常好的与问候,从后端的关注在基于Web的应用程序的分离,前端。这使得更容易设计和测试后端逻辑,相比于前端渲染。它是为Web开发框架(基于Web的应用程序是首先关注的),而不是一个Web前端开发框架(ASP.Net控制为基础)。

I would suggest that you need to be very comfortable with HMTL markup, and how HTTP + HTML communication works in order to be successful with an MVC project. The use of javascript is also very explicit. MVC is very nice with regards to a separation of concerns from back end, and front end in web based applications. This makes it easier to design and test the back-end logic, in comparison to the front-end rendering. It is a framework for web developers (web based applications are the first concern), not a developer framework for a web front end (ASP.Net controls based).

这篇关于难道ASP.NET MVC使用常规的工具箱控件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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