I have the following master-detail scenario:
A company table and BO
A Dept table and BO
A DataGridView with a BusinessBindingSource
Everything works as expected. I'm able to include my grid to participate in the editing etc. etc. nice!!!
Questions:
1. I have a button to add a row to the "DeptBO". Works as expected. What I need is that after adding the new row to send the user to the new added row in the grid. If I call the "Me.DataGridView1.Focus()" I get to the grid but not to the "new" row. I tried Add(), NewRow() in combination with "NavigatetoPrimaryKey" etc. but no luck.
2. If I enter data into the grid and then save everything goes as expected. If I programatically change my DeptsBO through the calling of a button and then saving the values I don't get the results to be saved. (Similar code to the sample provided in "Saving and Other Programmatic Access" documentation). If I do both (grid & through code) the data on the grid gets saved but not the one through code. Need to "sync" BO with Grid.
3. Need the equivalent of "AfterRowColChange" (Visual Foxpro) in DataGridView. It must be simple but I cannot figure which one is the right one to use and form that matter how to "sync" the row movement in the DataGridView with the BO. Is this done for you?
I spend tooooooooooooooo much time trying to figure the above. Any ideas.
Thanks
Fernando