Sharing the goodness…
Beth Massi is a Senior Program Manager on the Visual Studio team at Microsoft and a community champion for business application developers. Learn more about Beth.
More videos »
I just released two more videos (#15, #16) in the Forms Over Data video series. One is on understanding data binding and how it works from database all the way to the controls you see on forms. We talk about the relationship between the TableAdapter, the BindingSource and the DataSet and I show how to work with data in your code.
The second one explains how to update related data tables like I explained in this post. This video doesn't go into how to set up the transactions but you can read about how to do that here. I've also attached the code from the videos here.
I enjoyed your lessons very much.
Thanks for sharing.
I am new to Dot net Framework. can you suggest me some Video series through which i can learn more about the functionality of the Framework
My mail id is email@example.com
Please send me the links for the dotnet Video Series
Indeed, your object-binding class is very natty. I do have a question however. I've been learning VB.Net for the past 1.5 years, and have focussed on data manipulation. The problem is I prefer not to work with tableAdapters and dataAdapters; instead preferring to work with dataTables and dataSets. I know, essentially, they are the same thing, but my theory is, if the data application breaks using the gui model, I would not know the first thing about code, and so if I work with the code I will be able to reason the problem with the app. Am I making a short rod for a long back here?
I really got a lot out of your data binding video. When the user presses the delete button on the BindingNabvigator, I want to ask him if he's sure & depending on his answer, either let the delete go through or cancel it. Where (in which event) and how is done?
شكرا لك، لقد أفدتنا حق الإفادة. لطالما شاهدت الكثير من الفيديوات حول هذا الموضوع ولم أستطع التمكن من أي شيء إلا الأن....شكرا لك
Beth!!! Thank you so much for your "How do I" video series and this blog.
I've Never struggled so hard in my life on a learning curve as I have to get a grip on the .NET/Visual Basic -Visual Studio tools.
I learn a little bit, then have to double back to learn something else. Then run ahead. And back.
I'm constantly on the verge of a break-through.
But, then I stumble across one of your videos and everything fits together (until the next crash)
I've gone through this often enough to know that it's just how I learn. And that eventually it WILL actually make sense to me. So I'm sticking with it.
But, the best part of the process is the help I've gotten from you.
And I just wanted to say, "Thanks" Thank you very, very much.
(Do you think it will make sense to me someday?)
hi beth massi,
I LOVE U. U R SO COMPASSIONATE.
thank you so much for VB video..I dont know how can i express my gratitude. I wish I could take u out for dinner.
Hi betmassi, I was watching your forms over data videos and i was trying to apply your customer-orders video but instead i used customer-invoices instead. However, i ran into a performance issue as i have over 20000+ invoices. When i loaded the invoice table on Form Load it just took a long time.
Is there a simple way to overcome this? Like filter the invoice bases on customerID on demand instead of loading thousands of records initially into the dataset.
I really learned a lot from your videos, it makes life much easier for me of not having to code everything but let the VS IDE does the work for me.
Thanks a lot Beth Massi
All the videos are here: http://msdn2.microsoft.com/en-us/vbasic/bb466226.aspx
You can overwrite the delete code by handling the BindingNavigatorDeleteItem.Click event (just double click on the delete button). Then on the BindingNavigator, set the DeleteItem property to (none). Then you can write your code into the click event handler. When you want to delete the row you call BindingSource.RemoveCurrent().
You'll need to create a parameterized query. You can do this by adding a query to your tableadapter that limits your data returned. Please watch video #4 and #15 and read this post on how to create parameterized queries: http://blogs.msdn.com/bethmassi/archive/2007/05/25/creating-a-parameterized-query.aspx
Thanks, I did write a parameterized query(FillInvoicesByCustomerID). So to create the customer-invoices relationship, I have to call the
FillInvoicesByCustomerID when the user clicks on the FIRST,NEXT,PREV,LAST buttons? Basically, i have to handle all these events and pass in the appropriate customerID??
Here is a code snipnet of my code.
Private Sub BindingNavigatorMoveNextItem_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles BindingNavigatorMoveNextItem.Click
FillInvoicesByCustomerID(CustomerBindingSource.Position + 1)
Private Sub FillInvoicesByCustomerID(ByVal index As Integer)
Dim row As MainTabDataSet.CustomerRow
row = CType(CType(Me.CustomerBindingSource(index), DataRowView).Row, MainTabDataSet.CustomerRow)
Catch ex As Exception
You are awesome! Ever since I saw the Binding source, Binding Navigator and Typed-Dataset over a year ago I saw their potential. But I have had some serious issues learning how to use them in a professional environment.
Over the past year, I have taken little nibbles and written a small web-app and a small WinForms app that uses typed datasets and binding.
I have a rather large WinForms project coming up and I have decided to go “all out” use DataSets over Winforms with binding for the new project.
I am so very happy that I now have good set of videos for my team to review. It will be mandatory for all project members to review and study every single one of these videos.
Some random questions:
Is there a plan to release a better VS DataSet Visualizer for Typed Datasets?
Do you have any reference literature (blogs, articles, etc) that discusses writing against the partial class of the Typed Dataset? Especially reasons, planning and strategy for injecting business logic into the partial class of the dataset.