您好..我正在使用Windows应用程序,在那个如何从另一个表单刷新datagridview [英] Hello there..I am working with windows application, In that how to refresh datagridview from another form

查看:80
本文介绍了您好..我正在使用Windows应用程序,在那个如何从另一个表单刷新datagridview的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好。



我有两种形式

1.Items: - 这包含一个gridview和一个按钮添加项目

2.添加项目: - 包含插入项目的输入屏幕



每当我点击添加项目屏幕中的项目按钮将打开第二个屏幕,即添加项目,我已填写数据并单击以保存。



数据将保存到数据库和表格将被关闭..



之后我想刷新我在第一张表格上的Datagridview ...



请帮助我。

Hello all.

I have two forms
1.Items:- This contains a gridview and one button Add Item
2.Add Items:- This contains input screen to insert items

Whenever I click to Add Item button in Items screen it will open second screen i.e. Add Items, where I have filled data and click to save.

Data will save to database and form will be closed..

after that I would like to refresh my Datagridview which is on first form...

please help me for that.

推荐答案

好吧,忽略我的评论。我在你的问题主题中没有看到 windows 。 :笑:



见这个帖子:

http://stackoverflow.com/questions/2395624/how-to-refresh-datagridview-when-closing-child-form [ ^ ]



-KR
Well, Ignore my comment. I did't see the "windows" in the subject of your question. :laugh:

See this thread:
http://stackoverflow.com/questions/2395624/how-to-refresh-datagridview-when-closing-child-form[^]

-KR


请参阅我的文章,以便以一般方式回答这些问题:Many问题立刻回答 - Windows窗体或WPF视窗 [ ^ ]。



-SA
Please see my article written to answer such questions in a general way: Many Questions Answered at Once — Collaboration between Windows Forms or WPF Windows[^].

—SA


这篇关于您好..我正在使用Windows应用程序,在那个如何从另一个表单刷新datagridview的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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