Master-Detail Navigation |
|
|
Practical Learning: Using Master-Detail Navigation |
Column Name | Data Type | Other Properties |
AssetTypeID | int | Primary Key: True Identity: Yes |
AssetType | varchar | Length: 40 Allow Nulls: cleared |
AssetTypeID | AssetType |
1 | Business Management |
2 | Order Processing |
3 | Store Items Production |
AssetID | AssetTypeID | Make | Model |
1 | 1 | HP | Laser Jet 4200dtn |
2 | 3 | Scotcher | S-65G |
3 | 1 | IBM | NetVista M42 |
4 | 3 | Bobel Systems | BBL36 |
5 | 2 | DDP | AltaPOS 70DS |
6 | 2 | DDP | AltaPOS 70DS |
7 | 3 | Emery Thompson | 2HSC-W |
8 | 1 | Olympus | C-50 |
9 | 1 | Gateway | 200XL |
10 | 3 | Technogel | BF-50 |
|
Private Sub CompanyAssets_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.SqlDataAdapter1.Fill(Me.DsIceCream1) Me.SqlDataAdapter2.Fill(Me.DsIceCream1) End Sub |
Private Sub btnClose_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnClose.Click Close() End Sub |
Private Sub btnFirst_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnFirst.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = 0 End Sub |
Private Sub btnPrevious_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnPrevious.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position - 1 End Sub |
Private Sub btnNext_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnNext.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position + 1 End Sub |
Private Sub btnLast_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnLast.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Count - 1 End Sub |
Private Sub btnCompAssets_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCompAssets.Click Dim frmAssets As CompanyAssets = New CompanyAssets frmAssets.ShowDialog() End Sub |
Private Sub CompanyAssets_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Me.SqlDataAdapter1.Fill(Me.DsIceCream1) Me.SqlDataAdapter2.Fill(Me.DsIceCream1) Me.dvwAssets.RowFilter = "AssetTypeID = " + Me.txtAssetTypeID.Text End Sub Private Sub btnClose_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnClose.Click Close() End Sub Private Sub btnFirst_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnFirst.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = 0 Me.dvwAssets.RowFilter = "AssetTypeID = " + Me.txtAssetTypeID.Text End Sub Private Sub btnPrevious_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnPrevious.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position - 1 Me.dvwAssets.RowFilter = "AssetTypeID = " + Me.txtAssetTypeID.Text End Sub Private Sub btnNext_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnNext.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position + 1 Me.dvwAssets.RowFilter = "AssetTypeID = " + Me.txtAssetTypeID.Text End Sub Private Sub btnLast_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnLast.Click Me.BindingContext(Me.DsIceCream1, "AssetCategories").Position = _ Me.BindingContext(Me.DsIceCream1, "AssetCategories").Count - 1 Me.dvwAssets.RowFilter = "AssetTypeID = " + Me.txtAssetTypeID.Text End Sub End Class |
|
||
Previous | Copyright © 2004-2010 FunctionX, Inc. | Next |
|