Silverlight / WPF - Insert command call - Asked By David on 21-Jul-11 04:02 PM

Earn up to 10 extra points for answering this tough question.
 I am asking again for help to finish my project I started 18 months ago when I retired and still have no clue how to  finish it

Private Sub BindingNavigatorAddNewItem_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BindingNavigatorAddNewItem.Click


'What goes in here to call and run a Dataset-Tableadapter-insert command to

'select a row from a Datagridview-form and run the insert-command to put

'that row into Table2

' I am lost completely as what to do!!!




Me.taManager.UpdateAll(Me.CoursesPlayedDataSet)

CoursesPlayedDataSet.AcceptChanges()

End Sub

 Thanks David

Venkatesh Bathineni replied to David on 25-Jul-11 06:20 AM
Hi David,

i want to know few thing before suggesting some solution.
1) Are you using DataBinding for displaying data in datagridview..?
2) if not. please try to publish the approach you are following displaying data in datagridview.


David replied to Venkatesh Bathineni on 25-Jul-11 02:27 PM
 Hi Venkatesh
 Thanks for your reply 
  Are you using DataBinding for displaying data in datagridview..? yes I am using the binding navigator in a Datagrid view of all courses to select which one to insert from the Table "Courses" into Table "Courses_played"
 When I open and edit the dataset/tableadapter and run the text for the insert command Execute query it asks for the course number and I just enter one of the Prikey key numbers and click execute and it works inserting a line from table Course into Table Courses_played  But I have no idea how to call this command to work from a datagrid view when running the programme. 
 I appreciate any help you can give me

 Thanks
David