如何在vb.net Windows窗体中使用datagridview插入数据? [英] how to insert data using datagridview in vb.net windows form?
问题描述
嗨朋友
如何使用vb.net中的datagridview将数据插入数据库?我想使用datagird作为输入字段.我不想绑定gridview.
how can i insert data to database using datagridview in vb.net? i want to use the datagird as input filed. i dont want to bind the gridview.
请提供任何想法或示例代码
please give any idea or sample code
预先感谢
通过Faisal
推荐答案
是的,您可以做到,但是要做很多工作,请注意,您的要求太过传统,以至于没有专业的示例代码.
Yes you can do it, but a bunch of work, be aware it is so unconventional what you ask, that there is no professional sample code.
正在类比地问:有人可以给我一个例子,说明如何在高速公路上向后行驶最好的100个车.
It is asking in an analogy: can somebody give me an example how to drive the best 100 backwards on the highway.
如果使用数据库,则无论如何都要使用一些保存数据的东西.可以是实体,数据集,上下文或绑定用户界面(例如,数据网格视图)以让用户处理数据的任何其他对象.
If you use databases you use in anyway something which holds your data. Which can be entities, DataSets, context or any other object to which you bind a user interface (for instance a datagridview) to let the user handle the data.
可以更新数据.
这篇关于如何在vb.net Windows窗体中使用datagridview插入数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!