简体   繁体   English

插入,更新和删除数据

[英]Inserting , updating and deleting of Data

I want to make a control that show list of bounded data like in grid view but I want to be able to insert new record from the same control 我想制作一个控件,以在网格视图中显示绑定数据的列表,但我希望能够从同一控件中插入新记录

what is the best asp.net control I can use to do that (GridView , FormView or DetailsView)? 我可以用来做到这一点的最好的asp.net控件(GridView,FormView或DetailsView)是什么? and why? 为什么呢?

Thanks in Advance 提前致谢

You can do that with all three. 您可以同时使用这三个。 If you want to know how, there are some good tutorials on the official ASP.NET website, here . 如果你想知道怎么回事,有官方ASP.NET网站上的一些好的教程, 这里

The choice between them is a formatting/layout decision. 它们之间的选择是格式/布局决定。 A GridView produces a table, showing multiple records, while a DetailsView shows one at a time. GridView生成一张表,显示多个记录,而DetailsView一次显示一个记录。 A FormView lets you display the data however you want, but required much more effort, since you have to provide the HTML. FormView使您可以根据需要显示数据,但是需要付出更多的努力,因为必须提供HTML。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 刷新按钮 - 插入,删除,更新后刷新数据网格视图 - Refresh button - Refreshing data grid view after inserting, deleting, updating 为什么我们在sql表中插入或更新或删除数据时使用“@” - why we use “@” while inserting or updating or deleting data in sql table sqlcommand执行查询不更新删除和插入 - sqlcommand execute query not updating deleting and inserting 在Excel中插入和更新数据 - Inserting and updating data in Excel 从StreamingAssets统一选择,插入,删除和更新数据库 - SELECTING, INSERTING, DELETING and UPDATING a database from the StreamingAssets in unity 为什么在更新 model 的子列表时,EF Core 在删除之前插入而不是先删除再插入? - Why does EF Core inserts before deleting instead of deleting and then inserting when updating a child list of a model? 使用DataSet检索,更新数据并将数据插入SQLite - Use DataSet for retrieving, updating and inserting data to SQLite 更新与另一个表对象(NxN)相关的实体对象(插入,删除) - Updating an entity object with relation to another table-object (NxN) (Inserting, deleting) NHibernate:在更新/删除/插入视图上映射的类时是否可以使用存储过程? - NHibernate: Is it possible to use stored proc when updating/deleting/inserting a class mapped on view? 插入和删除不匹配的记录 - Inserting and deleting mismatching records
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM