📄 productsdataset.designer.vb
字号:
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Function FindByProductCategoryID(ByVal ProductCategoryID As Integer) As ProductCategoryRow
Return CType(Me.Rows.Find(New Object() {ProductCategoryID}),ProductCategoryRow)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Overridable Function GetEnumerator() As System.Collections.IEnumerator Implements System.Collections.IEnumerable.GetEnumerator
Return Me.Rows.GetEnumerator
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Overrides Function Clone() As System.Data.DataTable
Dim cln As ProductCategoryDataTable = CType(MyBase.Clone,ProductCategoryDataTable)
cln.InitVars
Return cln
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Function CreateInstance() As System.Data.DataTable
Return New ProductCategoryDataTable
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Friend Sub InitVars()
Me.columnProductCategoryID = MyBase.Columns("ProductCategoryID")
Me.columnName = MyBase.Columns("Name")
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Private Sub InitClass()
Me.columnProductCategoryID = New System.Data.DataColumn("ProductCategoryID", GetType(Integer), Nothing, System.Data.MappingType.Element)
MyBase.Columns.Add(Me.columnProductCategoryID)
Me.columnName = New System.Data.DataColumn("Name", GetType(String), Nothing, System.Data.MappingType.Element)
MyBase.Columns.Add(Me.columnName)
Me.Constraints.Add(New System.Data.UniqueConstraint("Constraint1", New System.Data.DataColumn() {Me.columnProductCategoryID}, true))
Me.columnProductCategoryID.AutoIncrement = true
Me.columnProductCategoryID.AllowDBNull = false
Me.columnProductCategoryID.ReadOnly = true
Me.columnProductCategoryID.Unique = true
Me.columnName.AllowDBNull = false
Me.columnName.MaxLength = 50
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Function NewProductCategoryRow() As ProductCategoryRow
Return CType(Me.NewRow,ProductCategoryRow)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Function NewRowFromBuilder(ByVal builder As System.Data.DataRowBuilder) As System.Data.DataRow
Return New ProductCategoryRow(builder)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Function GetRowType() As System.Type
Return GetType(ProductCategoryRow)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Sub OnRowChanged(ByVal e As System.Data.DataRowChangeEventArgs)
MyBase.OnRowChanged(e)
If (Not (Me.ProductCategoryRowChangedEvent) Is Nothing) Then
RaiseEvent ProductCategoryRowChanged(Me, New ProductCategoryRowChangeEvent(CType(e.Row,ProductCategoryRow), e.Action))
End If
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Sub OnRowChanging(ByVal e As System.Data.DataRowChangeEventArgs)
MyBase.OnRowChanging(e)
If (Not (Me.ProductCategoryRowChangingEvent) Is Nothing) Then
RaiseEvent ProductCategoryRowChanging(Me, New ProductCategoryRowChangeEvent(CType(e.Row,ProductCategoryRow), e.Action))
End If
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Sub OnRowDeleted(ByVal e As System.Data.DataRowChangeEventArgs)
MyBase.OnRowDeleted(e)
If (Not (Me.ProductCategoryRowDeletedEvent) Is Nothing) Then
RaiseEvent ProductCategoryRowDeleted(Me, New ProductCategoryRowChangeEvent(CType(e.Row,ProductCategoryRow), e.Action))
End If
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Protected Overrides Sub OnRowDeleting(ByVal e As System.Data.DataRowChangeEventArgs)
MyBase.OnRowDeleting(e)
If (Not (Me.ProductCategoryRowDeletingEvent) Is Nothing) Then
RaiseEvent ProductCategoryRowDeleting(Me, New ProductCategoryRowChangeEvent(CType(e.Row,ProductCategoryRow), e.Action))
End If
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Sub RemoveProductCategoryRow(ByVal row As ProductCategoryRow)
Me.Rows.Remove(row)
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Shared Function GetTypedTableSchema(ByVal xs As System.Xml.Schema.XmlSchemaSet) As System.Xml.Schema.XmlSchemaComplexType
Dim type As System.Xml.Schema.XmlSchemaComplexType = New System.Xml.Schema.XmlSchemaComplexType
Dim sequence As System.Xml.Schema.XmlSchemaSequence = New System.Xml.Schema.XmlSchemaSequence
Dim ds As ProductsDataSet = New ProductsDataSet
xs.Add(ds.GetSchemaSerializable)
Dim any1 As System.Xml.Schema.XmlSchemaAny = New System.Xml.Schema.XmlSchemaAny
any1.Namespace = "http://www.w3.org/2001/XMLSchema"
any1.MinOccurs = New Decimal(0)
any1.MaxOccurs = Decimal.MaxValue
any1.ProcessContents = System.Xml.Schema.XmlSchemaContentProcessing.Lax
sequence.Items.Add(any1)
Dim any2 As System.Xml.Schema.XmlSchemaAny = New System.Xml.Schema.XmlSchemaAny
any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1"
any2.MinOccurs = New Decimal(1)
any2.ProcessContents = System.Xml.Schema.XmlSchemaContentProcessing.Lax
sequence.Items.Add(any2)
Dim attribute1 As System.Xml.Schema.XmlSchemaAttribute = New System.Xml.Schema.XmlSchemaAttribute
attribute1.Name = "namespace"
attribute1.FixedValue = ds.Namespace
type.Attributes.Add(attribute1)
Dim attribute2 As System.Xml.Schema.XmlSchemaAttribute = New System.Xml.Schema.XmlSchemaAttribute
attribute2.Name = "tableTypeName"
attribute2.FixedValue = "ProductCategoryDataTable"
type.Attributes.Add(attribute2)
type.Particle = sequence
Return type
End Function
End Class
Partial Public Class ProductRow
Inherits System.Data.DataRow
Private tableProduct As ProductDataTable
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Friend Sub New(ByVal rb As System.Data.DataRowBuilder)
MyBase.New(rb)
Me.tableProduct = CType(Me.Table,ProductDataTable)
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property ProductID() As Integer
Get
Return CType(Me(Me.tableProduct.ProductIDColumn),Integer)
End Get
Set
Me(Me.tableProduct.ProductIDColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property Name() As String
Get
Return CType(Me(Me.tableProduct.NameColumn),String)
End Get
Set
Me(Me.tableProduct.NameColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property Color() As String
Get
Try
Return CType(Me(Me.tableProduct.ColorColumn),String)
Catch e As System.InvalidCastException
Throw New System.Data.StrongTypingException("The value for column 'Color' in table 'Product' is DBNull.", e)
End Try
End Get
Set
Me(Me.tableProduct.ColorColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property ListPrice() As Decimal
Get
Return CType(Me(Me.tableProduct.ListPriceColumn),Decimal)
End Get
Set
Me(Me.tableProduct.ListPriceColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property Size() As String
Get
Try
Return CType(Me(Me.tableProduct.SizeColumn),String)
Catch e As System.InvalidCastException
Throw New System.Data.StrongTypingException("The value for column 'Size' in table 'Product' is DBNull.", e)
End Try
End Get
Set
Me(Me.tableProduct.SizeColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property ProductCategoryID() As Integer
Get
Return CType(Me(Me.tableProduct.ProductCategoryIDColumn),Integer)
End Get
Set
Me(Me.tableProduct.ProductCategoryIDColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property ProductCategoryRow() As ProductCategoryRow
Get
Return CType(Me.GetParentRow(Me.Table.ParentRelations("Product_ProductCategory_FK")),ProductCategoryRow)
End Get
Set
Me.SetParentRow(value, Me.Table.ParentRelations("Product_ProductCategory_FK"))
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Function IsColorNull() As Boolean
Return Me.IsNull(Me.tableProduct.ColorColumn)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Sub SetColorNull()
Me(Me.tableProduct.ColorColumn) = System.Convert.DBNull
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Function IsSizeNull() As Boolean
Return Me.IsNull(Me.tableProduct.SizeColumn)
End Function
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Sub SetSizeNull()
Me(Me.tableProduct.SizeColumn) = System.Convert.DBNull
End Sub
End Class
Partial Public Class ProductCategoryRow
Inherits System.Data.DataRow
Private tableProductCategory As ProductCategoryDataTable
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Friend Sub New(ByVal rb As System.Data.DataRowBuilder)
MyBase.New(rb)
Me.tableProductCategory = CType(Me.Table,ProductCategoryDataTable)
End Sub
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property ProductCategoryID() As Integer
Get
Return CType(Me(Me.tableProductCategory.ProductCategoryIDColumn),Integer)
End Get
Set
Me(Me.tableProductCategory.ProductCategoryIDColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Property Name() As String
Get
Return CType(Me(Me.tableProductCategory.NameColumn),String)
End Get
Set
Me(Me.tableProductCategory.NameColumn) = value
End Set
End Property
<System.Diagnostics.DebuggerNonUserCodeAttribute()> _
Public Function GetProductRows() As ProductRow()
Return CType(MyBase.GetChildRows(Me.Table.ChildRelations("Product_ProductCategory_FK")),ProductRow())
End Function
End Class
Public Class ProductRowChangeEvent
Inherits System.EventArgs
Private eventRow As ProductRow
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -