Update only one instance of datagridview row values

Not sure how to ask this, but here goes...

Software: Vb.net 2005

I have a datagridview that updates records fine, but the problem is all of the previous instances has the same row values in them.
I want to fix it so only one instance is loaded.
See attached.Test-Form-1.pdfTest-Form-2.pdf

Thanks for any help
dave_skyAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Fernando SotoRetiredCommented:
What do you mean by this, "but the problem is all of the previous instances has the same row values in them. I want to fix it so only one instance is loaded."?

I see that you have two forms with the same info. Are the two forms fed from the same data source object?
0
dave_skyAuthor Commented:
Yes, the two forms are fed from the same data source object (MonarchSQL database in a server).
0
Fernando SotoRetiredCommented:
Well if you set the DataSource object to the same object if you update one all will see the update.
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

dave_skyAuthor Commented:
Here is the code I have...

Thanks for your patience. It has been years since I did any developing and I have forgot a lot...

NewPlumbingWorkorderDetailJST-sample.pdf
0
Fernando SotoRetiredCommented:
Hi dave_sky;

First please use CODE blocks when posting code. The simple way to do it is place the cursor where you want to insert the code then click the CODE icon in the tool bar of the "Write Comment" edit box and then do a "Ctrl V" and the info in the clipboard will be pasted between the code blocks. This will help us to see a properly formatted code. First does the code compile? Secondly you have code that have If statements that do nothing for example
For Each dr In MonarchSQLDataSet.tblNewPlumbingWorkorder.Rows
    If dr.RowState = DataRowState.Modified Or dr.RowState = DataRowState.Added Then 
    End If
Next dr 

Open in new window

There are no statements to execute if the test in the If statement is true.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
dave_skyAuthor Commented:
Thanks for your help!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.