' ///////////////////////////////////////////////////////////////////////////
' // Description: Data Access class for the table 'Mitarbeitereinstellung'
' // Generated by LLBLGen v1.21.2003.712 Final on: Donnerstag, 12. März 2009, 09:08:02
' // Because the Base Class already implements IDispose, this class doesn't.
' ///////////////////////////////////////////////////////////////////////////
Imports System
Imports System.Data
Imports System.Data.SqlTypes
Imports System.Data.SqlClient
Namespace TKB.VV.DB
'''
''' Purpose: Data Access class for the table 'Mitarbeitereinstellung'.
'''
Public Class clsMitarbeitereinstellung
Inherits clsDBInteractionBase
#Region " Class Member Declarations "
Private m_bPendenzen, m_bAktivitaeten, m_bApplikationsuebersicht, m_bVertragsuebersicht As SqlBoolean
Private m_iMitarbeitereinstellungnr, m_iMitarbeiternr, m_iMitarbeiternrOld As SqlInt32
#End Region
'''
''' Purpose: Class constructor.
'''
Public Sub New()
' // Nothing for now.
End Sub
'''
''' Purpose: Insert method. This method will insert one new row into the database.
'''
''' True if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeiternr. May be SqlInt32.Null
''' - bVertragsuebersicht. May be SqlBoolean.Null
''' - bPendenzen. May be SqlBoolean.Null
''' - bAktivitaeten. May be SqlBoolean.Null
''' - bApplikationsuebersicht. May be SqlBoolean.Null
'''
''' Properties set after a succesful call of this method:
'''
''' - iMitarbeitereinstellungnr
''' - iErrorCode
'''
'''
Overrides Public Function Insert() As Boolean
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_Insert]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(New SqlParameter("@iMitarbeiternr", SqlDbType.Int, 4, ParameterDirection.Input, True, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternr))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bVertragsuebersicht", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bVertragsuebersicht))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bPendenzen", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bPendenzen))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bAktivitaeten", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bAktivitaeten))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bApplikationsuebersicht", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bApplikationsuebersicht))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeitereinstellungnr", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeitereinstellungnr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
m_iRowsAffected = scmCmdToExecute.ExecuteNonQuery()
m_iMitarbeitereinstellungnr = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iMitarbeitereinstellungnr").Value, Integer))
m_iErrorCode = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iErrorCode").Value, SqlInt32))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_Insert' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return True
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::Insert::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
End Try
End Function
'''
''' Purpose: Update method. This method will Update one existing row in the database.
'''
''' True if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeitereinstellungnr
''' - iMitarbeiternr. May be SqlInt32.Null
''' - bVertragsuebersicht. May be SqlBoolean.Null
''' - bPendenzen. May be SqlBoolean.Null
''' - bAktivitaeten. May be SqlBoolean.Null
''' - bApplikationsuebersicht. May be SqlBoolean.Null
'''
''' Properties set after a succesful call of this method:
'''
'''
Overrides Public Function Update() As Boolean
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_Update]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(New SqlParameter("@iMitarbeitereinstellungnr", SqlDbType.Int, 4, ParameterDirection.Input, False, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeitereinstellungnr))
scmCmdToExecute.Parameters.Add(New SqlParameter("@iMitarbeiternr", SqlDbType.Int, 4, ParameterDirection.Input, True, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternr))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bVertragsuebersicht", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bVertragsuebersicht))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bPendenzen", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bPendenzen))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bAktivitaeten", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bAktivitaeten))
scmCmdToExecute.Parameters.Add(New SqlParameter("@bApplikationsuebersicht", SqlDbType.Bit, 1, ParameterDirection.Input, True, 0, 0, "", DataRowVersion.Proposed, m_bApplikationsuebersicht))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
m_iRowsAffected = scmCmdToExecute.ExecuteNonQuery()
m_iErrorCode = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iErrorCode").Value, SqlInt32))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_Update' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return True
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::Update::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
End Try
End Function
'''
''' Purpose: Update method for updating one or more rows using the Foreign Key 'Mitarbeiternr.
''' This method will Update one or more existing rows in the database. It will reset the field 'Mitarbeiternr' in
''' all rows which have as value for this field the value as set in property 'iMitarbeiternrOld' to
''' the value as set in property 'iMitarbeiternr'.
'''
''' True if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeiternr. May be SqlInt32.Null
''' - iMitarbeiternrOld. May be SqlInt32.Null
'''
''' Properties set after a succesful call of this method:
'''
'''
Public Function UpdateAllWMitarbeiternrLogic() As Boolean
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_UpdateAllWMitarbeiternrLogic]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeiternr", SqlDbType.Int, 4, ParameterDirection.Input, false, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeiternrOld", SqlDbType.Int, 4, ParameterDirection.Input, True, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternrOld))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
m_iRowsAffected = scmCmdToExecute.ExecuteNonQuery()
m_iMitarbeiternr = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iMitarbeiternr").Value, Integer))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_UpdateAllWMitarbeiternrLogic' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return True
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::UpdateAllWMitarbeiternrLogic::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
End Try
End Function
'''
''' Purpose: Delete method. This method will Delete one existing row in the database, based on the Primary Key.
'''
''' True if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeitereinstellungnr
'''
''' Properties set after a succesful call of this method:
'''
'''
Overrides Public Function Delete() As Boolean
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_Delete]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(New SqlParameter("@iMitarbeitereinstellungnr", SqlDbType.Int, 4, ParameterDirection.Input, False, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeitereinstellungnr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
m_iRowsAffected = scmCmdToExecute.ExecuteNonQuery()
m_iErrorCode = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iErrorCode").Value, SqlInt32))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_Delete' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return True
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::Delete::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
End Try
End Function
'''
''' Purpose: Delete method for a foreign key. This method will Delete one or more rows from the database, based on the Foreign Key 'Mitarbeiternr'
'''
''' true if succeeded, false otherwise
'''
''' Properties needed for this method:
'''
''' - iMitarbeiternr. May be SqlInt32.Null
'''
''' Properties set after a succesful call of this method:
'''
'''
Public Function DeleteAllWMitarbeiternrLogic() As Boolean
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_DeleteAllWMitarbeiternrLogic]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeiternr", SqlDbType.Int, 4, ParameterDirection.Input, false, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
m_iRowsAffected = scmCmdToExecute.ExecuteNonQuery()
m_iMitarbeiternr = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iMitarbeiternr").Value, Integer))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_DeleteAllWMitarbeiternrLogic' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return True
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::DeleteAllWMitarbeiternrLogic::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
End Try
End Function
'''
''' Purpose: Select method. This method will Select one existing row from the database, based on the Primary Key.
'''
''' DataTable object if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeitereinstellungnr
'''
''' Properties set after a succesful call of this method:
'''
''' - iErrorCode
''' - iMitarbeitereinstellungnr
''' - iMitarbeiternr
''' - bVertragsuebersicht
''' - bPendenzen
''' - bAktivitaeten
''' - bApplikationsuebersicht
'''
''' Will fill all properties corresponding with a field in the table with the value of the row selected.
'''
Overrides Public Function SelectOne() As DataTable
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_SelectOne]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
Dim dtToReturn As DataTable = new DataTable("Mitarbeitereinstellung")
Dim sdaAdapter As SqlDataAdapter = new SqlDataAdapter(scmCmdToExecute)
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeitereinstellungnr", SqlDbType.Int, 4, ParameterDirection.Input, False, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeitereinstellungnr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
sdaAdapter.Fill(dtToReturn)
m_iErrorCode = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iErrorCode").Value, SqlInt32))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_SelectOne' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
If dtToReturn.Rows.Count > 0 Then
m_iMitarbeitereinstellungnr = New SqlInt32(CType(dtToReturn.Rows(0)("Mitarbeitereinstellungnr"), Integer))
If dtToReturn.Rows(0)("Mitarbeiternr") Is System.DBNull.Value Then
m_iMitarbeiternr = SqlInt32.Null
Else
m_iMitarbeiternr = New SqlInt32(CType(dtToReturn.Rows(0)("Mitarbeiternr"), Integer))
End If
If dtToReturn.Rows(0)("Vertragsuebersicht") Is System.DBNull.Value Then
m_bVertragsuebersicht = SqlBoolean.Null
Else
m_bVertragsuebersicht = New SqlBoolean(CType(dtToReturn.Rows(0)("Vertragsuebersicht"), Boolean))
End If
If dtToReturn.Rows(0)("Pendenzen") Is System.DBNull.Value Then
m_bPendenzen = SqlBoolean.Null
Else
m_bPendenzen = New SqlBoolean(CType(dtToReturn.Rows(0)("Pendenzen"), Boolean))
End If
If dtToReturn.Rows(0)("Aktivitaeten") Is System.DBNull.Value Then
m_bAktivitaeten = SqlBoolean.Null
Else
m_bAktivitaeten = New SqlBoolean(CType(dtToReturn.Rows(0)("Aktivitaeten"), Boolean))
End If
If dtToReturn.Rows(0)("Applikationsuebersicht") Is System.DBNull.Value Then
m_bApplikationsuebersicht = SqlBoolean.Null
Else
m_bApplikationsuebersicht = New SqlBoolean(CType(dtToReturn.Rows(0)("Applikationsuebersicht"), Boolean))
End If
End If
Return dtToReturn
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::SelectOne::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
sdaAdapter.Dispose()
End Try
End Function
'''
''' Purpose: SelectAll method. This method will Select all rows from the table.
'''
''' DataTable object if succeeded, otherwise an Exception is thrown.
'''
''' Properties set after a succesful call of this method:
'''
'''
Overrides Public Function SelectAll() As DataTable
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_SelectAll]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
Dim dtToReturn As DataTable = new DataTable("Mitarbeitereinstellung")
Dim sdaAdapter As SqlDataAdapter = new SqlDataAdapter(scmCmdToExecute)
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
sdaAdapter.Fill(dtToReturn)
m_iErrorCode = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iErrorCode").Value, SqlInt32))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_SelectAll' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return dtToReturn
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::SelectAll::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
sdaAdapter.Dispose()
End Try
End Function
'''
''' Purpose: Select method for a foreign key. This method will Select one or more rows from the database, based on the Foreign Key 'Mitarbeiternr'
'''
''' DataTable object if succeeded, otherwise an Exception is thrown.
'''
''' Properties needed for this method:
'''
''' - iMitarbeiternr. May be SqlInt32.Null
'''
''' Properties set after a succesful call of this method:
'''
'''
Public Function SelectAllWMitarbeiternrLogic() As DataTable
Dim scmCmdToExecute As SqlCommand = New SqlCommand()
scmCmdToExecute.CommandText = "dbo.[pr_Mitarbeitereinstellung_SelectAllWMitarbeiternrLogic]"
scmCmdToExecute.CommandType = CommandType.StoredProcedure
Dim dtToReturn As DataTable = new DataTable("Mitarbeitereinstellung")
Dim sdaAdapter As SqlDataAdapter = new SqlDataAdapter(scmCmdToExecute)
' // Use base class' connection object
scmCmdToExecute.Connection = m_scoMainConnection
Try
scmCmdToExecute.Parameters.Add(new SqlParameter("@iMitarbeiternr", SqlDbType.Int, 4, ParameterDirection.Input, True, 10, 0, "", DataRowVersion.Proposed, m_iMitarbeiternr))
scmCmdToExecute.Parameters.Add(new SqlParameter("@iErrorCode", SqlDbType.Int, 4, ParameterDirection.Output, True, 10, 0, "", DataRowVersion.Proposed, m_iErrorCode))
If m_bMainConnectionIsCreatedLocal Then
' // Open connection.
m_scoMainConnection.Open()
Else
If m_cpMainConnectionProvider.bIsTransactionPending Then
scmCmdToExecute.Transaction = m_cpMainConnectionProvider.stCurrentTransaction
End If
End If
' // Execute query.
sdaAdapter.Fill(dtToReturn)
m_iMitarbeiternr = New SqlInt32(CType(scmCmdToExecute.Parameters.Item("@iMitarbeiternr").Value, Integer))
If Not m_iErrorCode.Equals(New SqlInt32(LLBLError.AllOk)) Then
' // Throw error.
Throw New Exception("Stored Procedure 'pr_Mitarbeitereinstellung_SelectAllWMitarbeiternrLogic' reported the ErrorCode: " & m_iErrorCode.ToString())
End If
Return dtToReturn
Catch ex As Exception
' // some error occured. Bubble it to caller and encapsulate Exception object
Throw New Exception("clsMitarbeitereinstellung::SelectAllWMitarbeiternrLogic::Error occured.", ex)
Finally
If m_bMainConnectionIsCreatedLocal Then
' // Close connection.
m_scoMainConnection.Close()
End If
scmCmdToExecute.Dispose()
sdaAdapter.Dispose()
End Try
End Function
#Region " Class Property Declarations "
Public Property [iMitarbeitereinstellungnr]() As SqlInt32
Get
Return m_iMitarbeitereinstellungnr
End Get
Set(ByVal Value As SqlInt32)
Dim iMitarbeitereinstellungnrTmp As SqlInt32 = Value
If iMitarbeitereinstellungnrTmp.IsNull Then
Throw New ArgumentOutOfRangeException("iMitarbeitereinstellungnr", "iMitarbeitereinstellungnr can't be NULL")
End If
m_iMitarbeitereinstellungnr = Value
End Set
End Property
Public Property [iMitarbeiternr]() As SqlInt32
Get
Return m_iMitarbeiternr
End Get
Set(ByVal Value As SqlInt32)
m_iMitarbeiternr = Value
End Set
End Property
Public Property [iMitarbeiternrOld]() As SqlInt32
Get
Return m_iMitarbeiternrOld
End Get
Set(ByVal Value As SqlInt32)
m_iMitarbeiternrOld = Value
End Set
End Property
Public Property [bVertragsuebersicht]() As SqlBoolean
Get
Return m_bVertragsuebersicht
End Get
Set(ByVal Value As SqlBoolean)
m_bVertragsuebersicht = Value
End Set
End Property
Public Property [bPendenzen]() As SqlBoolean
Get
Return m_bPendenzen
End Get
Set(ByVal Value As SqlBoolean)
m_bPendenzen = Value
End Set
End Property
Public Property [bAktivitaeten]() As SqlBoolean
Get
Return m_bAktivitaeten
End Get
Set(ByVal Value As SqlBoolean)
m_bAktivitaeten = Value
End Set
End Property
Public Property [bApplikationsuebersicht]() As SqlBoolean
Get
Return m_bApplikationsuebersicht
End Get
Set(ByVal Value As SqlBoolean)
m_bApplikationsuebersicht = Value
End Set
End Property
#End Region
End Class
End Namespace