Ayooya

i have datagrid in parent form, when i add record to table from child form, the record is n't updated in datagrid records

how i can update datagrid.



Re: Visual Basic General refresh datagrid

cybertaz69

Your child form has a different dataset than the parent form. See the link below on how the share the data set.

http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=1258953&SiteID=1

or merge the two datasets at form close or by code when your done with changes.






Re: Visual Basic General refresh datagrid

Ayooya

pls clear because i can't understand



Re: Visual Basic General refresh datagrid

cybertaz69

On this topic there are ton of places to make a mistake or create a coding error. Let me ask a few question so I can help.

Are you using how are you storing the data in your app Type dataset, reg dataset, collection or other.

How are you currently trying to pass the data from the child form to the Parent Or are you using a golble source

To explain the code in the previos post.

Using a typed dataset. You create a dataset instance on the parent form. For all child forms instead of creating a new instance of the dataset it reuses the parents original data set. Add a row in a child form and the parent instanly has the row added......