BlakeMcKenna
asked on
Modifying form data and showing reflected change in another form at same time???
I have a program where I have one form that contains a DataGridView which is bound to a SQL Server Table. When the user selects a row from the grid...another form (maintenance form) will pop up containing the data from the grid. The user will then make changes to the data and then save the data and have it immediately reflect the changes in the grid on the first form.
Unfortunately, I'm not sure how to code for this in the maintenance form.
What I'm thinking is that I need to make a reference to the dataset object (linked to the grid), in the maintenance form where I make the changes. I was thinking of something like this.
'The following Event is in the Maintenance Form
Private Sub btnSave_Click()
'Make a reference to the Form containing the Grid
frmProducts.dsEmployee.Tab les(0).Row s(?).Item( "Category" ) = cmbCategory.Text
End Sub
dsEmployee is the DataSet bound to the grid.
I hope I've explained myself adequately.
Thanks,
Unfortunately, I'm not sure how to code for this in the maintenance form.
What I'm thinking is that I need to make a reference to the dataset object (linked to the grid), in the maintenance form where I make the changes. I was thinking of something like this.
'The following Event is in the Maintenance Form
Private Sub btnSave_Click()
'Make a reference to the Form containing the Grid
frmProducts.dsEmployee.Tab
End Sub
dsEmployee is the DataSet bound to the grid.
I hope I've explained myself adequately.
Thanks,
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon/html/vbconDataSets.asp