diff --git a/App_Code/ClsAC.vb b/App_Code/ClsAC.vb
index f3b7100ec..45e0a37f1 100644
--- a/App_Code/ClsAC.vb
+++ b/App_Code/ClsAC.vb
@@ -3245,11 +3245,13 @@ Public Class ClsAC
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsAC2.vb b/App_Code/ClsAC2.vb
index 2a51e1786..50fbb9284 100644
--- a/App_Code/ClsAC2.vb
+++ b/App_Code/ClsAC2.vb
@@ -152,11 +152,12 @@ Public Class ClsAC2
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsAF.vb b/App_Code/ClsAF.vb
index cd7bbc863..1ddd0ed3a 100644
--- a/App_Code/ClsAF.vb
+++ b/App_Code/ClsAF.vb
@@ -4520,10 +4520,13 @@ Public Class ClsAF
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsAIMMGM.vb b/App_Code/ClsAIMMGM.vb
index b9268d0f6..58eb962a9 100644
--- a/App_Code/ClsAIMMGM.vb
+++ b/App_Code/ClsAIMMGM.vb
@@ -746,11 +746,12 @@ Public Class ClsAIMMGM
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsAcarreos.vb b/App_Code/ClsAcarreos.vb
index 6c42c9419..0c1a3abe6 100644
--- a/App_Code/ClsAcarreos.vb
+++ b/App_Code/ClsAcarreos.vb
@@ -1350,11 +1350,12 @@ Public Class ClsAcarreos
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsAcumuladores.vb b/App_Code/ClsAcumuladores.vb
index 7f01aa20f..4f8badf3f 100644
--- a/App_Code/ClsAcumuladores.vb
+++ b/App_Code/ClsAcumuladores.vb
@@ -1232,12 +1232,14 @@ Public Class ClsAcumuladores
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If disposing Then
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsBancos.vb b/App_Code/ClsBancos.vb
index 858a38c2f..72ba56b54 100644
--- a/App_Code/ClsBancos.vb
+++ b/App_Code/ClsBancos.vb
@@ -4273,12 +4273,14 @@ Public Class ClsBancos
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsBase.vb b/App_Code/ClsBase.vb
index 73949c0f0..77d090808 100644
--- a/App_Code/ClsBase.vb
+++ b/App_Code/ClsBase.vb
@@ -181,13 +181,12 @@ Public Class ClsBase
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- If Not SqlConexion Is Nothing Then
- CerrarConexion()
- SqlConexion.Dispose()
- End If
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not sqlCommand Is Nothing Then sqlCommand.Dispose() : sqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsCGame.vb b/App_Code/ClsCGame.vb
index 50d497b46..dc66c337d 100644
--- a/App_Code/ClsCGame.vb
+++ b/App_Code/ClsCGame.vb
@@ -3400,11 +3400,14 @@ Public Class ClsCGame
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsCRM.vb b/App_Code/ClsCRM.vb
index 76da1aa43..334a04744 100644
--- a/App_Code/ClsCRM.vb
+++ b/App_Code/ClsCRM.vb
@@ -1137,11 +1137,15 @@ Public Class ClsCRM
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsClaseBase.vb b/App_Code/ClsClaseBase.vb
index d5857b782..ca229a5e4 100644
--- a/App_Code/ClsClaseBase.vb
+++ b/App_Code/ClsClaseBase.vb
@@ -247,6 +247,7 @@ Public Class ClsClaseBase
SqlConexion.Close()
End Sub
#End Region
+
Public Sub Dispose() Implements IDisposable.Dispose
ConexionClose()
If (SqlConexion IsNot Nothing) Then
@@ -279,6 +280,9 @@ Public Class ClsClaseBase
End Sub
+
+
+
End Class
Public Class parametroQuery
diff --git a/App_Code/ClsClasificaciones.vb b/App_Code/ClsClasificaciones.vb
index a321f9f37..7c7e28372 100644
--- a/App_Code/ClsClasificaciones.vb
+++ b/App_Code/ClsClasificaciones.vb
@@ -610,13 +610,15 @@ Public Class ClsClasificaciones
' IDisposable
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- ' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If disposing Then
+ ' TODO: dispose managed state (managed objects).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsClientes.vb b/App_Code/ClsClientes.vb
index 5b4bd4c6b..364a870bc 100644
--- a/App_Code/ClsClientes.vb
+++ b/App_Code/ClsClientes.vb
@@ -1757,13 +1757,15 @@ Public Class ClsClientes
' IDisposable
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- ' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If disposing Then
+ ' TODO: dispose managed state (managed objects).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsCompEstatusFactura.vb b/App_Code/ClsCompEstatusFactura.vb
index 816d07e87..7408fe201 100644
--- a/App_Code/ClsCompEstatusFactura.vb
+++ b/App_Code/ClsCompEstatusFactura.vb
@@ -203,11 +203,12 @@ Public Class ClsCompEstatusFactura
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsCompProveedores.vb b/App_Code/ClsCompProveedores.vb
index 4594ff303..8a062f23f 100644
--- a/App_Code/ClsCompProveedores.vb
+++ b/App_Code/ClsCompProveedores.vb
@@ -1908,11 +1908,13 @@ Public Class ClsCompProveedores
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsCompras.vb b/App_Code/ClsCompras.vb
index 8737fc436..4aa180e78 100644
--- a/App_Code/ClsCompras.vb
+++ b/App_Code/ClsCompras.vb
@@ -1884,11 +1884,12 @@ Public Class ClsCompras
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsContPAQi.vb b/App_Code/ClsContPAQi.vb
index bef333969..97ce501d7 100644
--- a/App_Code/ClsContPAQi.vb
+++ b/App_Code/ClsContPAQi.vb
@@ -11204,12 +11204,14 @@ Public Class ClsContPAQi
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- StrSQL.Clear()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsContPAQi2.vb b/App_Code/ClsContPAQi2.vb
index 34d41d4bd..0e1a8185a 100644
--- a/App_Code/ClsContPAQi2.vb
+++ b/App_Code/ClsContPAQi2.vb
@@ -1017,12 +1017,14 @@ Public Class ClsContPAQi2
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- StrSQL.Clear()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsContabilidad.vb b/App_Code/ClsContabilidad.vb
index 266a9a71c..728d1d200 100644
--- a/App_Code/ClsContabilidad.vb
+++ b/App_Code/ClsContabilidad.vb
@@ -6234,12 +6234,15 @@ Public Class ClsContabilidad
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsContratos.vb b/App_Code/ClsContratos.vb
index 99671766b..54e7cf9ff 100644
--- a/App_Code/ClsContratos.vb
+++ b/App_Code/ClsContratos.vb
@@ -3596,12 +3596,14 @@ Public Class ClsContratos
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not Dataset Is Nothing Then Dataset.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
-
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not Dataset Is Nothing Then Dataset.Dispose() : Dataset = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsDG.vb b/App_Code/ClsDG.vb
index b4b540c45..1c44c0193 100644
--- a/App_Code/ClsDG.vb
+++ b/App_Code/ClsDG.vb
@@ -638,11 +638,14 @@ Public Class ClsDG
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsDesarrollo.vb b/App_Code/ClsDesarrollo.vb
index ea17e0339..c3694ced1 100644
--- a/App_Code/ClsDesarrollo.vb
+++ b/App_Code/ClsDesarrollo.vb
@@ -548,13 +548,14 @@ Public Class ClsDesarrollo
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
+
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
' TODO: set large fields to null.
End If
diff --git a/App_Code/ClsEdoc.vb b/App_Code/ClsEdoc.vb
index 6731807ea..82e6cf1e7 100644
--- a/App_Code/ClsEdoc.vb
+++ b/App_Code/ClsEdoc.vb
@@ -306,10 +306,12 @@ Public Class ClsEdoc
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsEdocumentacion.vb b/App_Code/ClsEdocumentacion.vb
index dc764e2bb..dd22807c3 100644
--- a/App_Code/ClsEdocumentacion.vb
+++ b/App_Code/ClsEdocumentacion.vb
@@ -621,12 +621,14 @@ Public Class ClsEdocumentacion
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If disposing Then
+ ' TODO: Liberar otro estado (objetos administrados).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsEdosFinancieros.vb b/App_Code/ClsEdosFinancieros.vb
index 3f1aad05f..89b5ea2b1 100644
--- a/App_Code/ClsEdosFinancieros.vb
+++ b/App_Code/ClsEdosFinancieros.vb
@@ -881,13 +881,15 @@ Public Class ClsEdosFinancieros
If disposing Then
' TODO: free other state (managed objects).
'RegistraCierreConexion()
- SqlConexion.Close()
- SqlConexion.Dispose()
+ If Not DT Is Nothing Then DT.Dispose() : DT = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
- If Not DT Is Nothing Then DT.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
' TODO: free your own state (unmanaged objects).
' TODO: set large fields to null.
diff --git a/App_Code/ClsEncuestas.vb b/App_Code/ClsEncuestas.vb
index bafb08bd6..119c69534 100644
--- a/App_Code/ClsEncuestas.vb
+++ b/App_Code/ClsEncuestas.vb
@@ -701,11 +701,15 @@ Public Class ClsEncuestas
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsEsquemasComisiones.vb b/App_Code/ClsEsquemasComisiones.vb
index 5528c2772..dc2e03932 100644
--- a/App_Code/ClsEsquemasComisiones.vb
+++ b/App_Code/ClsEsquemasComisiones.vb
@@ -499,12 +499,13 @@ Public Class ClsEsquemasComisiones
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsEstatusFactura.vb b/App_Code/ClsEstatusFactura.vb
index 893538e23..9cf75cf64 100644
--- a/App_Code/ClsEstatusFactura.vb
+++ b/App_Code/ClsEstatusFactura.vb
@@ -230,11 +230,12 @@ Public Class ClsEstatusFactura
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsEventos.vb b/App_Code/ClsEventos.vb
index c631009a2..e08351f16 100644
--- a/App_Code/ClsEventos.vb
+++ b/App_Code/ClsEventos.vb
@@ -224,11 +224,11 @@ Public Class ClsEventos
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsFISConfiguracion.vb b/App_Code/ClsFISConfiguracion.vb
index a1d8ddf32..52d7365c5 100644
--- a/App_Code/ClsFISConfiguracion.vb
+++ b/App_Code/ClsFISConfiguracion.vb
@@ -174,11 +174,12 @@ Public Class ClsFISConfiguracion
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsFinanzas.vb b/App_Code/ClsFinanzas.vb
index 3a032bc3a..20a6fdb07 100644
--- a/App_Code/ClsFinanzas.vb
+++ b/App_Code/ClsFinanzas.vb
@@ -200,11 +200,14 @@ Public Class ClsFinanzas
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
diff --git a/App_Code/ClsFlotillas.vb b/App_Code/ClsFlotillas.vb
index 17350750b..f9ff51f34 100644
--- a/App_Code/ClsFlotillas.vb
+++ b/App_Code/ClsFlotillas.vb
@@ -738,12 +738,13 @@ Public Class ClsFlotillas
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsGPS.vb b/App_Code/ClsGPS.vb
index 790d42e8d..21ddfea1e 100644
--- a/App_Code/ClsGPS.vb
+++ b/App_Code/ClsGPS.vb
@@ -5693,21 +5693,22 @@ Public Class ClsGPS
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
- If Not Dataset Is Nothing Then
- Dataset.Clear()
- Dataset.Dispose()
- Dataset = Nothing
- End If
+ If disposing Then
+ ' TODO: Liberar otro estado (objetos administrados).
+
+
If Not DtPosiciones Is Nothing Then DtPosiciones.Dispose() : DtPosiciones = Nothing
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not Dataset Is Nothing Then Dataset.Dispose() : Dataset = Nothing
If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsGPSHerramientas.vb b/App_Code/ClsGPSHerramientas.vb
index 493863bad..2d0c6e456 100644
--- a/App_Code/ClsGPSHerramientas.vb
+++ b/App_Code/ClsGPSHerramientas.vb
@@ -187,11 +187,12 @@ Public Class ClsGPSHerramientas
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsGenerales.vb b/App_Code/ClsGenerales.vb
index becb87884..e594b96c2 100644
--- a/App_Code/ClsGenerales.vb
+++ b/App_Code/ClsGenerales.vb
@@ -3327,22 +3327,7 @@ Public Class ClsGenerales
#End Region
- Protected Overridable Sub Dispose(ByVal disposing As Boolean)
- If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- End If
-
- ' TODO: Liberar su propio estado (objetos no administrados).
- ' TODO: Establecer campos grandes como Null.
- End If
- disposedValue = True
- End Sub
+
#Region "CRUD_Edoc_DocumentacionTipo"
@@ -3489,15 +3474,42 @@ Public Class ClsGenerales
#End Region
-#Region " IDisposable Support "
- ' Visual Basic agregó este código para implementar correctamente el modelo descartable.
+
+#Region "IDisposable Support"
+
+
+ ' IDisposable
+ Protected Overridable Sub Dispose(disposing As Boolean)
+ If Not Me.disposedValue Then
+ If disposing Then
+ ' TODO: dispose managed state (managed objects).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+ End If
+
+ ' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
+ ' TODO: set large fields to null.
+ End If
+ Me.disposedValue = True
+ End Sub
+
+
+
+ ' This code added by Visual Basic to correctly implement the disposable pattern.
Public Sub Dispose() Implements IDisposable.Dispose
- ' No cambie este código. Coloque el código de limpieza en Dispose (ByVal que se dispone como Boolean).
+ ' Do not change this code. Put cleanup code in Dispose(disposing As Boolean) above.
ConexionClose()
Dispose(True)
GC.SuppressFinalize(Me)
End Sub
-#End Region
+#End Region
+
+
#Region " P O L I Z A V I R T U A L "
Public Function ModelosAutosGet(CveEmpresa As Integer) As Boolean
diff --git a/App_Code/ClsGralFolios.vb b/App_Code/ClsGralFolios.vb
index 2705071c7..6c5f231b4 100644
--- a/App_Code/ClsGralFolios.vb
+++ b/App_Code/ClsGralFolios.vb
@@ -276,12 +276,14 @@ Public Class ClsGralFolios
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- ' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsGralProductosServiciosCaracteristicas.vb b/App_Code/ClsGralProductosServiciosCaracteristicas.vb
index 6c2ea130b..8ee0d7822 100644
--- a/App_Code/ClsGralProductosServiciosCaracteristicas.vb
+++ b/App_Code/ClsGralProductosServiciosCaracteristicas.vb
@@ -305,10 +305,12 @@ Public Class ClsGralProductosServiciosCaracteristicas
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsImpuestos.vb b/App_Code/ClsImpuestos.vb
index f4fd2c684..28d2929e3 100644
--- a/App_Code/ClsImpuestos.vb
+++ b/App_Code/ClsImpuestos.vb
@@ -146,11 +146,14 @@ Public Class ClsImpuestos
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsIndicadores.vb b/App_Code/ClsIndicadores.vb
index 625ddd31f..c9d8275aa 100644
--- a/App_Code/ClsIndicadores.vb
+++ b/App_Code/ClsIndicadores.vb
@@ -128,10 +128,12 @@ Public Class ClsIndicadores
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsInventarios.vb b/App_Code/ClsInventarios.vb
index 43eab1487..c256e98fe 100644
--- a/App_Code/ClsInventarios.vb
+++ b/App_Code/ClsInventarios.vb
@@ -5751,10 +5751,11 @@ Public Class ClsInventarios
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsLeyendasFiscales.vb b/App_Code/ClsLeyendasFiscales.vb
index 55c873e76..429a00b01 100644
--- a/App_Code/ClsLeyendasFiscales.vb
+++ b/App_Code/ClsLeyendasFiscales.vb
@@ -191,11 +191,12 @@ Public Class ClsLeyendasFiscales
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsMF.vb b/App_Code/ClsMF.vb
index 72ea537ca..e49c01e47 100644
--- a/App_Code/ClsMF.vb
+++ b/App_Code/ClsMF.vb
@@ -710,11 +710,14 @@ Public Class ClsMF
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsMetodosPagos.vb b/App_Code/ClsMetodosPagos.vb
index 59097d1df..e21006c56 100644
--- a/App_Code/ClsMetodosPagos.vb
+++ b/App_Code/ClsMetodosPagos.vb
@@ -113,11 +113,12 @@ Public Class ClsMetodosPagos
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsModulos.vb b/App_Code/ClsModulos.vb
index 3c47376f4..7c8e84877 100644
--- a/App_Code/ClsModulos.vb
+++ b/App_Code/ClsModulos.vb
@@ -412,11 +412,12 @@ Public Class ClsModulos
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsMonedas.vb b/App_Code/ClsMonedas.vb
index 26d96091d..3a4ac8dcd 100644
--- a/App_Code/ClsMonedas.vb
+++ b/App_Code/ClsMonedas.vb
@@ -134,11 +134,12 @@ Public Class ClsMonedas
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsMovimientos.vb b/App_Code/ClsMovimientos.vb
index 0193ebf94..680fbc2ae 100644
--- a/App_Code/ClsMovimientos.vb
+++ b/App_Code/ClsMovimientos.vb
@@ -1751,14 +1751,15 @@ Public Class ClsMovimientos
' IDisposable
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- ' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If disposing Then
+ ' TODO: dispose managed state (managed objects).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsNominas.vb b/App_Code/ClsNominas.vb
index f57a14a3c..8f4ffb729 100644
--- a/App_Code/ClsNominas.vb
+++ b/App_Code/ClsNominas.vb
@@ -2878,11 +2878,14 @@ Public Class ClsNominas
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
If disposing Then
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DTSet Is Nothing Then DTSet.Dispose() : DTSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
End If
diff --git a/App_Code/ClsOC.vb b/App_Code/ClsOC.vb
index 913c6ddf7..bd1832379 100644
--- a/App_Code/ClsOC.vb
+++ b/App_Code/ClsOC.vb
@@ -2611,11 +2611,13 @@ Public Class ClsOC
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
If disposing Then
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
End If
disposedValue = True
diff --git a/App_Code/ClsOIEventos.vb b/App_Code/ClsOIEventos.vb
index 457ba77d3..bc70c3569 100644
--- a/App_Code/ClsOIEventos.vb
+++ b/App_Code/ClsOIEventos.vb
@@ -3162,12 +3162,14 @@ Public Class ClsOIEventos
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If disposing Then
+ ' TODO: Liberar otro estado (objetos administrados).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsOS.vb b/App_Code/ClsOS.vb
index 431ef2037..42e8c4cd2 100644
--- a/App_Code/ClsOS.vb
+++ b/App_Code/ClsOS.vb
@@ -1680,10 +1680,12 @@ Public Class ClsOS
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsPV.vb b/App_Code/ClsPV.vb
index 63f2bb39e..382f34065 100644
--- a/App_Code/ClsPV.vb
+++ b/App_Code/ClsPV.vb
@@ -208,12 +208,13 @@ Public Class ClsPV
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsPresupuestos.vb b/App_Code/ClsPresupuestos.vb
index 2bf7542f8..54c45a729 100644
--- a/App_Code/ClsPresupuestos.vb
+++ b/App_Code/ClsPresupuestos.vb
@@ -755,10 +755,12 @@ Public Class ClsPresupuestos
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsProductosServicios.vb b/App_Code/ClsProductosServicios.vb
index 113c97ce0..1b1a08d6f 100644
--- a/App_Code/ClsProductosServicios.vb
+++ b/App_Code/ClsProductosServicios.vb
@@ -2141,11 +2141,13 @@ Public Class ClsProductosServicios
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsProsEncuestas.vb b/App_Code/ClsProsEncuestas.vb
index dc005bd79..7a74c21c6 100644
--- a/App_Code/ClsProsEncuestas.vb
+++ b/App_Code/ClsProsEncuestas.vb
@@ -775,10 +775,11 @@ Public Class ClsProsEncuestas
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsProspectos.vb b/App_Code/ClsProspectos.vb
index adfc2b6cd..2866b3324 100644
--- a/App_Code/ClsProspectos.vb
+++ b/App_Code/ClsProspectos.vb
@@ -4615,10 +4615,13 @@ Public Class ClsProspectos
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsProyectos.vb b/App_Code/ClsProyectos.vb
index 31b371e85..030fc7686 100644
--- a/App_Code/ClsProyectos.vb
+++ b/App_Code/ClsProyectos.vb
@@ -233,10 +233,12 @@ Public Class ClsProyectos
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsPruebasJJMQ.vb b/App_Code/ClsPruebasJJMQ.vb
index 3bd297b6e..1a812e2b5 100644
--- a/App_Code/ClsPruebasJJMQ.vb
+++ b/App_Code/ClsPruebasJJMQ.vb
@@ -157,11 +157,12 @@ Public Class ClsPruebasJJMQ
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
StrSQL.Clear()
End If
diff --git a/App_Code/ClsPuntoVenta.vb b/App_Code/ClsPuntoVenta.vb
index 79f8f82ed..e524ce6bb 100644
--- a/App_Code/ClsPuntoVenta.vb
+++ b/App_Code/ClsPuntoVenta.vb
@@ -429,12 +429,12 @@ Public Class ClsPuntoVenta
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsRH.vb b/App_Code/ClsRH.vb
index c7d98a06d..455ae5763 100644
--- a/App_Code/ClsRH.vb
+++ b/App_Code/ClsRH.vb
@@ -7111,10 +7111,12 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsRMA.vb b/App_Code/ClsRMA.vb
index b29752ac6..25726a92e 100644
--- a/App_Code/ClsRMA.vb
+++ b/App_Code/ClsRMA.vb
@@ -203,11 +203,13 @@ Public Class ClsRMA
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsSAT.vb b/App_Code/ClsSAT.vb
index ec5a7b30e..62d6f4521 100644
--- a/App_Code/ClsSAT.vb
+++ b/App_Code/ClsSAT.vb
@@ -451,11 +451,12 @@ Public Class ClsSAT
' TODO: dispose managed state (managed objects).
'ConexionUpdate()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
diff --git a/App_Code/ClsSCTLicencias.vb b/App_Code/ClsSCTLicencias.vb
index bdf704c01..7ae89385a 100644
--- a/App_Code/ClsSCTLicencias.vb
+++ b/App_Code/ClsSCTLicencias.vb
@@ -247,13 +247,16 @@ Public Class ClsSCTLicencias
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
If disposing Then
+
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
' TODO: Liberar su propio estado (objetos no administrados).
' TODO: Establecer campos grandes como Null.
diff --git a/App_Code/ClsSeguimiento.vb b/App_Code/ClsSeguimiento.vb
index 96b21a7cf..d3359629a 100644
--- a/App_Code/ClsSeguimiento.vb
+++ b/App_Code/ClsSeguimiento.vb
@@ -166,10 +166,10 @@ Public Class ClsSeguimiento
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsSisEmpresas.vb b/App_Code/ClsSisEmpresas.vb
index 8712432be..e96dd9a87 100644
--- a/App_Code/ClsSisEmpresas.vb
+++ b/App_Code/ClsSisEmpresas.vb
@@ -1846,14 +1846,15 @@ Public Class ClsSisEmpresas
' IDisposable
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- 'If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If disposing Then
+ ' TODO: Liberar otro estado (objetos administrados).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsSisNotificaciones.vb b/App_Code/ClsSisNotificaciones.vb
index 37eb2e654..bcf8af387 100644
--- a/App_Code/ClsSisNotificaciones.vb
+++ b/App_Code/ClsSisNotificaciones.vb
@@ -2063,22 +2063,25 @@ Public Class ClsSisNotificaciones
' IDisposable
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose() : SqlConexion = Nothing
- If Not DataSet Is Nothing Then
- DataSet.Clear()
- DataSet.Dispose() : DataSet = Nothing
- End If
+ If disposing Then
+
+
+
+ If Not DTNotificacionesGPS Is Nothing Then DTNotificacionesGPS.Dispose() : DTNotificacionesGPS = Nothing
+ If Not DTNotificacionesERP Is Nothing Then DTNotificacionesERP.Dispose() : DTNotificacionesERP = Nothing
+ If Not DTNotificacionesArmadas Is Nothing Then DTNotificacionesArmadas.Dispose() : DTNotificacionesArmadas = Nothing
+ If Not DTReportesProgramados Is Nothing Then DTReportesProgramados.Dispose() : DTReportesProgramados = Nothing
+ NotificacionesBitacora = ""
+
+
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
- If Not DTNotificacionesGPS Is Nothing Then DTNotificacionesGPS.Dispose() : DTNotificacionesGPS = Nothing
- If Not DTNotificacionesERP Is Nothing Then DTNotificacionesERP.Dispose() : DTNotificacionesERP = Nothing
- If Not DTNotificacionesArmadas Is Nothing Then DTNotificacionesArmadas.Dispose() : DTNotificacionesArmadas = Nothing
- If Not DTReportesProgramados Is Nothing Then DTReportesProgramados.Dispose() : DTNotificacionesGPS = Nothing
- NotificacionesBitacora = ""
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not DataSet Is Nothing Then DataSet.Dispose() : DataSet = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsSisParametros.vb b/App_Code/ClsSisParametros.vb
index 8ab040848..31ee3bc15 100644
--- a/App_Code/ClsSisParametros.vb
+++ b/App_Code/ClsSisParametros.vb
@@ -255,12 +255,15 @@ Public Class ClsSisParametros
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsSisProcesos.vb b/App_Code/ClsSisProcesos.vb
index a19a77896..573219743 100644
--- a/App_Code/ClsSisProcesos.vb
+++ b/App_Code/ClsSisProcesos.vb
@@ -216,11 +216,11 @@ Public Class ClsSisProcesos
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: Liberar su propio estado (objetos no administrados).
diff --git a/App_Code/ClsSisRoles.vb b/App_Code/ClsSisRoles.vb
index 85b9a7211..89e0fa672 100644
--- a/App_Code/ClsSisRoles.vb
+++ b/App_Code/ClsSisRoles.vb
@@ -336,10 +336,13 @@ Public Class ClsSisRoles
If Not Me.disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsSisUsuarios.vb b/App_Code/ClsSisUsuarios.vb
index 09896ce69..44acf89fc 100644
--- a/App_Code/ClsSisUsuarios.vb
+++ b/App_Code/ClsSisUsuarios.vb
@@ -2939,12 +2939,16 @@ Public Class ClsSisUsuarios
#Region "IDisposable Support"
Protected Overridable Sub Dispose(disposing As Boolean)
If Not Me.disposedValue Then
- If disposing Then
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If disposing Then
+
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
End If
End If
Me.disposedValue = True
diff --git a/App_Code/ClsStiReports.vb b/App_Code/ClsStiReports.vb
index fa533de0a..8d000882f 100644
--- a/App_Code/ClsStiReports.vb
+++ b/App_Code/ClsStiReports.vb
@@ -106,10 +106,13 @@ Public Class ClsStiReports
If Not disposedValue Then
If disposing Then
' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsSubProyectos.vb b/App_Code/ClsSubProyectos.vb
index eb0f0d55a..f07ce9213 100644
--- a/App_Code/ClsSubProyectos.vb
+++ b/App_Code/ClsSubProyectos.vb
@@ -299,12 +299,14 @@ Public Class ClsSubProyectos
' IDisposable
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
- If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ If disposing Then
+ ' TODO: Liberar otro estado (objetos administrados).
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
diff --git a/App_Code/ClsSucursales.vb b/App_Code/ClsSucursales.vb
index b7d3f0f00..e1d19cca9 100644
--- a/App_Code/ClsSucursales.vb
+++ b/App_Code/ClsSucursales.vb
@@ -351,11 +351,13 @@ Public Class ClsSucursales
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsTemporal.vb b/App_Code/ClsTemporal.vb
index f9ee5ca69..3b727f52c 100644
--- a/App_Code/ClsTemporal.vb
+++ b/App_Code/ClsTemporal.vb
@@ -291,12 +291,13 @@ Public Class ClsTemporal
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
- If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsTiposEventos.vb b/App_Code/ClsTiposEventos.vb
index 2905de837..76cb02e42 100644
--- a/App_Code/ClsTiposEventos.vb
+++ b/App_Code/ClsTiposEventos.vb
@@ -185,11 +185,12 @@ Public Class ClsTiposEventos
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsUnidadesMedida.vb b/App_Code/ClsUnidadesMedida.vb
index 69e51e5f8..542efe9bf 100644
--- a/App_Code/ClsUnidadesMedida.vb
+++ b/App_Code/ClsUnidadesMedida.vb
@@ -307,11 +307,13 @@ Public Class ClsUnidadesMedida
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsVentas.vb b/App_Code/ClsVentas.vb
index cee7e3770..2a6cf907c 100644
--- a/App_Code/ClsVentas.vb
+++ b/App_Code/ClsVentas.vb
@@ -5257,6 +5257,9 @@ Public Class ClsVentas
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
+
+
+
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
If Not Dataset Is Nothing Then Dataset.Dispose() : Dataset = Nothing
If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
@@ -5264,6 +5267,9 @@ Public Class ClsVentas
If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
+
+
+
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsVtaPromociones.vb b/App_Code/ClsVtaPromociones.vb
index f5e9e6bfa..3c11d5b04 100644
--- a/App_Code/ClsVtaPromociones.vb
+++ b/App_Code/ClsVtaPromociones.vb
@@ -139,11 +139,13 @@ Public Class ClsVtaPromociones
If Not Me.disposedValue Then
If disposing Then
' TODO: dispose managed state (managed objects).
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
- If Not SqlCommand Is Nothing Then SqlCommand.Dispose()
+
+
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
- If Not SqlConexion Is Nothing Then SqlConexion.Dispose()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
End If
' TODO: free unmanaged resources (unmanaged objects) and override Finalize() below.
diff --git a/App_Code/ClsVtaVendedores.vb b/App_Code/ClsVtaVendedores.vb
index 6949554e1..11c021c2d 100644
--- a/App_Code/ClsVtaVendedores.vb
+++ b/App_Code/ClsVtaVendedores.vb
@@ -265,13 +265,15 @@ Public Class ClsVtaVendedores
Protected Overridable Sub Dispose(ByVal disposing As Boolean)
If Not disposedValue Then
If disposing Then
- ' TODO: Liberar otro estado (objetos administrados).
- SqlConexion.Close()
- SqlConexion.Dispose()
- If Not Data Is Nothing Then Data.Dispose()
- If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose()
+ ' TODO: Liberar otro estado (objetos administrados).
+ If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
+ If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
+ If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
+ If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
+ If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
+ If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
- End If
+ End If
' TODO: Liberar su propio estado (objetos no administrados).
' TODO: Establecer campos grandes como Null.
diff --git a/Bancos/PopIEVentas.aspx.vb b/Bancos/PopIEVentas.aspx.vb
index 330068893..1336491e0 100644
--- a/Bancos/PopIEVentas.aspx.vb
+++ b/Bancos/PopIEVentas.aspx.vb
@@ -561,7 +561,7 @@ Partial Class Bancos_PopIEVentas
MovimientoPagar = Nothing
ArrIE = New ArrayList()
ArrIEFuncionariosEmpleados = New ArrayList()
- RFCCliente = ""
+ RFCCliente = "-1"
TxtFechaDocumento.Text = Now.ToShortDateString
diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb
index ef527e830..27585e0ea 100644
--- a/Compras/Compras.aspx.vb
+++ b/Compras/Compras.aspx.vb
@@ -6117,6 +6117,7 @@ Partial Class Compras_Compras
Case 25 'IEPS X Acreditar
If Not DdlTipoComprobante.SelectedValue.Contiene("Ant") Then
+ CveSubProyectoInsertar = CveSubProyecto
importeMovimiento = ImporteIEPSxAcreditar
importeMN = Math.Round(importeMovimiento, 2) * tipoCambioActual * Multiplicador
If tipoCambioActual > 1 Then Concepto += $" TC{tipoCambioActual} ${importeMovimiento.FormatoNumero(2)}"
@@ -6854,12 +6855,12 @@ Partial Class Compras_Compras
End If
End If
-
+ Else
+ If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then
+ ErrorPrepoliza = True
+ End If
End If
- 'If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then
- ' ErrorPrepoliza = True
- 'End If
End If
diff --git a/Compras/PopUpVerFactura.aspx.vb b/Compras/PopUpVerFactura.aspx.vb
index 7bf565dd8..19a607751 100644
--- a/Compras/PopUpVerFactura.aspx.vb
+++ b/Compras/PopUpVerFactura.aspx.vb
@@ -376,6 +376,12 @@ Partial Class PopUpVerFactura
If UrlParametros("CVEMOV") IsNot Nothing AndAlso UrlParametros("CVEMOV").ToString.ToEntero > 0 Then
ImprimeFormatoCartaPorte(UrlParametros("CVEMOV").ToString.ToEntero)
End If
+ End If
+
+ If UrlParametros("OP").ToString = "CARPOTIMBRE" Then
+ If UrlParametros("CVEMOV") IsNot Nothing AndAlso UrlParametros("CVEMOV").ToString.ToEntero > 0 Then
+ ImprimeFormatoCartaPorteTimbrado(UrlParametros("CVEMOV").ToString.ToEntero)
+ End If
End If
@@ -747,7 +753,7 @@ Partial Class PopUpVerFactura
#End Region
-#Region "OP = 'CARPO' - IMPRIME FORMATO CARTA PORTE"
+#Region "OP = 'CARPO' - IMPRIME FORMATO CARTA PORTE TIMBRADO"
Private Sub ImprimeFormatoCartaPorte(CveMovimiento As Integer)
If CveMovimiento > 0 Then
Dim ObjInv As New ClsInventarios
@@ -873,6 +879,345 @@ Partial Class PopUpVerFactura
End If
End Sub
+ Private Function ValorXML(n As XmlNode, Campo As String, Optional Retorno As String = "") As String
+ Dim o As XmlNode = n.Attributes.Cast(Of XmlAttribute)().SingleOrDefault(Function(a) String.Compare(a.Name, Campo, True) = 0)
+ If o Is Nothing Then
+ Return Retorno
+ Else
+ Return o.Value
+ End If
+ End Function
+
+ Private Sub ImprimeFormatoCartaPorteTimbrado(CveMovimiento As Integer)
+ If CveMovimiento > 0 Then
+
+ '01 Autotransporte Federal
+ '02 Transporte Marítimo
+ '03 Transporte Aéreo
+ '04 Transporte Ferroviario
+ '05 Ducto
+ Dim HtTransporte As New Hashtable()
+ HtTransporte.Add("01", "Autotransporte Federal")
+ HtTransporte.Add("02", "Transporte Marítimo")
+ HtTransporte.Add("03", "Transporte Aéreo")
+ HtTransporte.Add("04", "Transporte Ferroviario")
+ HtTransporte.Add("05", "Ducto")
+
+ 'EMISOR
+ Dim LugarExpedicion As String = ""
+ Dim ImgCBB As String = ""
+ 'COMPROBANTE
+ Dim SerieFolio As String = ""
+ Dim Telefono As String = ""
+ Dim SubTotal As Decimal = 0
+ Dim Descuentos As Decimal = 0
+ Dim Total As Decimal = 0
+ 'DATOS DEL CLIENTE
+ Dim ClienteRFC As String = ""
+ Dim ClienteNombre As String = ""
+ Dim ClienteUsoCFDi As String = ""
+
+ 'TRANSPORTE
+ Dim MedioTransporte As String = ""
+ Dim TransporteInternacional As String = ""
+ Dim PermisoSTCC As String = ""
+ Dim NumPermiso As String = ""
+ Dim Aseguradora As String = ""
+ Dim NumPolizaSeguro As String = ""
+ Dim PlacaVM As String = ""
+ Dim AnioModeloVM As String = ""
+ 'TIMBRADO
+ Dim FolioFiscal As String = ""
+ Dim NoCertificadoSAT As String = ""
+ Dim CadenaOriginal As String = ""
+ Dim NoSerieCertificado As String = ""
+ Dim FechaCertificacion As DateTime = Nothing
+ Dim SelloCFDi As String = ""
+ Dim SelloSAT As String = ""
+
+ Dim ObjInv As New ClsInventarios
+ If ObjInv.GetMovimientos(CveMovimiento, -1, -1, UsuarioActual.CveEmpresa) Then
+ If ObjInv.DtResultados.Rows.Count > 0 Then
+ Dim Dr As DataRow = ObjInv.DtResultados.Rows(0)
+ If Dr IsNot Nothing Then
+ SerieFolio = Dr("Folio").ToString
+ Telefono = Dr("Telefono1").ToString
+ End If
+ End If
+ End If
+ ObjInv.Dispose()
+
+ Dim DtConceptos As New DataTable()
+ DtConceptos.Columns.Add(New DataColumn("Cantidad", GetType(Decimal)))
+ DtConceptos.Columns.Add(New DataColumn("Unidad", GetType(String)))
+ DtConceptos.Columns.Add(New DataColumn("Descripcion", GetType(String)))
+ DtConceptos.Columns.Add(New DataColumn("ValorUnitario", GetType(Decimal)))
+ DtConceptos.Columns.Add(New DataColumn("Importe", GetType(Decimal)))
+
+ Dim DtUbicaciones As New DataTable()
+ DtUbicaciones.Columns.Add(New DataColumn("Distancia", GetType(String)))
+ DtUbicaciones.Columns.Add(New DataColumn("RFC", GetType(String)))
+ DtUbicaciones.Columns.Add(New DataColumn("Nombre", GetType(String)))
+ DtUbicaciones.Columns.Add(New DataColumn("FechaHoraSalida", GetType(DateTime)))
+ DtUbicaciones.Columns.Add(New DataColumn("Direccion", GetType(String)))
+
+ Dim DtMercancias As New DataTable()
+ DtMercancias.Columns.Add(New DataColumn("Cantidad", GetType(Decimal)))
+ DtMercancias.Columns.Add(New DataColumn("UnidadMedida", GetType(String)))
+ DtMercancias.Columns.Add(New DataColumn("Descripcion", GetType(String)))
+ DtMercancias.Columns.Add(New DataColumn("PesoEnKg", GetType(String)))
+
+ Dim DtOperadores As New DataTable()
+ DtOperadores.Columns.Add(New DataColumn("RFC", GetType(String)))
+ DtOperadores.Columns.Add(New DataColumn("NumLicencia", GetType(String)))
+ DtOperadores.Columns.Add(New DataColumn("NombreOperador", GetType(String)))
+
+ Dim XMLDoc As New XmlDocument
+ Dim Path As String = String.Format("{0}\{1}\{2}\{3}.{4}", UsuarioActual.Empresa.Ruta, "XML", "Tra", String.Format("Tra-{0}", SerieFolio), "xml")
+ Dim Archivo As New System.IO.FileInfo(Path)
+
+ If Archivo.Exists Then
+ Try
+ XMLDoc.Load(Path)
+ Catch ex As Exception
+ Try
+ Dim oReader = New StreamReader(Path, Encoding.GetEncoding("ISO-8859-1"))
+ XMLDoc.Load(oReader)
+ oReader.Dispose()
+ Catch ex2 As Exception
+ GuardaLog("Error al intentar leer el XML del SAT. Error:" & ex2.ToString())
+ End Try
+ End Try
+ End If
+
+ If XMLDoc IsNot Nothing AndAlso Archivo.Exists Then
+
+ Dim RutaCBB As String = String.Format("{0}\CBB\Tra-{1}.jpg", UsuarioActual.Empresa.Ruta, SerieFolio)
+ Dim ImagenCBB As New System.IO.FileInfo(RutaCBB)
+
+ Dim nodo As XmlNode = XMLDoc.DocumentElement
+
+ Dim Prefijo As String = If(XMLDoc.DocumentElement.Prefix = "", "cfd", XMLDoc.DocumentElement.Prefix)
+ Dim cfdVer As String = "http://www.sat.gob.mx/cfd/3"
+ Dim namespaces As New XmlNamespaceManager(XMLDoc.NameTable)
+
+ If Prefijo.ToLower <> "cfdi" Then cfdVer = "http://www.sat.gob.mx/cfd/2"
+ namespaces.AddNamespace(Prefijo, cfdVer)
+ namespaces.AddNamespace("tfd", "http://www.sat.gob.mx/TimbreFiscalDigital")
+ namespaces.AddNamespace("implocal", "http://www.sat.gob.mx/implocal")
+ namespaces.AddNamespace("registrofiscal", "http://www.sat.gob.mx/registrofiscal")
+ namespaces.AddNamespace("cartaporte", "http://www.sat.gob.mx/CartaPorte")
+
+ Dim nodeComprobante As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Comprobante", Prefijo), namespaces)
+ If nodeComprobante IsNot Nothing Then
+ LugarExpedicion = ValorXML(nodeComprobante, "LugarExpedicion")
+ SubTotal = ValorXML(nodeComprobante, "SubTotal").ToDecimal()
+ Total = ValorXML(nodeComprobante, "Total").ToDecimal()
+ End If
+
+ Dim nodeCliente As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Receptor", Prefijo), namespaces)
+
+ If nodeCliente IsNot Nothing Then
+ ClienteRFC = ValorXML(nodeCliente, "RFC")
+ ClienteNombre = ValorXML(nodeCliente, "Nombre")
+ Dim UsoCFDI = ValorXML(nodeCliente, "UsoCFDI")
+ ClienteUsoCFDi = String.Format("{0} - {1}", UsoCFDI, GlobalDTSATUsosCFDI().FiltroPrimeroValor("Descripcion", String.Format("UsoCFDI = '{0}'", UsoCFDI)))
+ End If
+
+ Dim nodeConceptos As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Conceptos", Prefijo), namespaces)
+
+ If nodeConceptos IsNot Nothing Then
+ For Each node As XmlNode In nodeConceptos.ChildNodes
+ Dim Row As DataRow = DtConceptos.NewRow
+
+ Row("Cantidad") = ValorXML(node, "Cantidad", "")
+ Row("Unidad") = ValorXML(node, "Unidad", "")
+ Row("Descripcion") = ValorXML(node, "Descripcion", "")
+ Row("ValorUnitario") = ValorXML(node, "ValorUnitario", "")
+ Row("Importe") = ValorXML(node, "Importe", "")
+
+ DtConceptos.Rows.Add(Row)
+ Next
+ End If
+
+
+ Dim nodeComp As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Complemento", Prefijo), namespaces)
+
+ Dim nodeCartaPorte As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:CartaPorte", "cartaporte"), namespaces)
+ If nodeCartaPorte IsNot Nothing Then
+ TransporteInternacional = ValorXML(nodeCartaPorte, "TranspInternac", "")
+ End If
+
+ Dim nodeAutotransporteFederal As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:AutotransporteFederal", "cartaporte"), namespaces)
+ If nodeAutotransporteFederal IsNot Nothing Then
+ PermisoSTCC = ValorXML(nodeAutotransporteFederal, "PermSCT", "")
+ NumPermiso = ValorXML(nodeAutotransporteFederal, "NumPermisoSCT", "")
+ Aseguradora = ValorXML(nodeAutotransporteFederal, "NombreAseg", "")
+ NumPolizaSeguro = ValorXML(nodeAutotransporteFederal, "NumPolizaSeguro", "")
+ End If
+
+ Dim nodeIdentificacionVehicular As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:IdentificacionVehicular", "cartaporte"), namespaces)
+ If nodeIdentificacionVehicular IsNot Nothing Then
+ PlacaVM = ValorXML(nodeIdentificacionVehicular, "PlacaVM", "")
+ AnioModeloVM = ValorXML(nodeIdentificacionVehicular, "AnioModeloVM", "")
+ End If
+
+ Dim nodeFiguraTransporte As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:FiguraTransporte", "cartaporte"), namespaces)
+ If nodeFiguraTransporte IsNot Nothing Then
+ Dim CveTransporte As String = ValorXML(nodeFiguraTransporte, "CveTransporte", "")
+ MedioTransporte = String.Format("{0} - {1}", CveTransporte, HtTransporte(CveTransporte).ToString())
+ End If
+
+ Dim nodeMercancias As XmlNodeList = nodeComp.SelectNodes(String.Format("//{0}:Mercancia", "cartaporte"), namespaces)
+ For Each node As XmlNode In nodeMercancias
+ Dim Row As DataRow = DtMercancias.NewRow
+
+ Row("Cantidad") = ValorXML(node, "Cantidad", "")
+ Row("UnidadMedida") = ValorXML(node, "Unidad", "")
+ Row("Descripcion") = ValorXML(node, "Descripcion", "")
+ Row("PesoEnKg") = ValorXML(node, "PesoEnKg", "")
+
+ DtMercancias.Rows.Add(Row)
+ Next
+
+ Dim nodeOperadores As XmlNodeList = nodeComp.SelectNodes(String.Format("//{0}:Operador", "cartaporte"), namespaces)
+ For Each node As XmlNode In nodeOperadores
+ Dim Row As DataRow = DtOperadores.NewRow
+
+ Row("RFC") = ValorXML(node, "RFCOperador", "")
+ Row("NumLicencia") = ValorXML(node, "NumLicencia", "")
+ Row("NombreOperador") = ValorXML(node, "NombreOperador", "")
+
+ DtOperadores.Rows.Add(Row)
+ Next
+
+
+ Dim nodeUbicaciones As XmlNodeList = nodeComp.SelectNodes(String.Format("//{0}:Ubicacion", "cartaporte"), namespaces)
+ For Each node As XmlNode In nodeUbicaciones
+ Dim Row As DataRow = DtUbicaciones.NewRow
+
+ Row("Distancia") = ValorXML(node, "DistanciaRecorrida", "")
+ Dim nodeOrigen = node.ChildNodes.Cast(Of XmlNode).FirstOrDefault(Function(x) x.Name = "cartaporte:Origen")
+ If nodeOrigen IsNot Nothing Then
+ Row("RFC") = ValorXML(nodeOrigen, "RFCRemitente", "")
+ Row("Nombre") = ValorXML(nodeOrigen, "NombreRemitente", "")
+ Row("FechaHoraSalida") = ValorXML(nodeOrigen, "FechaHoraSalida", "").ToDateTime()
+ End If
+
+ Dim nodeDestino = node.ChildNodes.Cast(Of XmlNode).FirstOrDefault(Function(x) x.Name = "cartaporte:Destino") 'node.SelectSingleNode(String.Format("//{0}:Destino", "cartaporte"), namespaces)
+ If nodeDestino IsNot Nothing Then
+ Row("RFC") = ValorXML(nodeDestino, "RFCDestinatario", "")
+ Row("Nombre") = ValorXML(nodeDestino, "NombreDestinatario", "")
+ Row("FechaHoraSalida") = ValorXML(nodeDestino, "FechaHoraProgLlegada", "").ToDateTime()
+ End If
+
+ Dim nodeDomicilio = node.ChildNodes.Cast(Of XmlNode).FirstOrDefault(Function(x) x.Name = "cartaporte:Domicilio") 'node.SelectSingleNode(String.Format("//{0}:Domicilio", "cartaporte"), namespaces)
+ If nodeDomicilio IsNot Nothing Then
+ Dim calle = ValorXML(nodeDomicilio, "Calle", "")
+ Dim Estado = ValorXML(nodeDomicilio, "Estado", "")
+ Dim Pais = ValorXML(nodeDomicilio, "MEX", "")
+ Dim CP = ValorXML(nodeDomicilio, "CodigoPostal", "")
+
+ Row("Direccion") = String.Format("{0} ,{1},{2}. CP {3}", calle, Estado, Pais, CP)
+ End If
+
+ DtUbicaciones.Rows.Add(Row)
+ Next
+
+ Dim nodeTFD As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:TimbreFiscalDigital", "tfd"), namespaces)
+ If nodeTFD IsNot Nothing Then
+ FolioFiscal = ValorXML(nodeTFD, "UUID", "")
+ NoSerieCertificado = ValorXML(nodeTFD, "NoCertificadoSAT", "")
+ FechaCertificacion = ValorXML(nodeTFD, "FechaTimbrado", "").ToDateTime
+ SelloCFDi = ValorXML(nodeTFD, "SelloCFD", "")
+ SelloSAT = ValorXML(nodeTFD, "SelloSAT", "")
+ NoCertificadoSAT = ValorXML(nodeTFD, "NoCertificadoSAT", "")
+
+ CadenaOriginal = "||1.0|" + FolioFiscal + "|" + FechaCertificacion.ToString("yyyy-MM-dd") + "T" + FechaCertificacion.ToString("HH:mm:ss") + "|" + SelloCFDi + "|" + NoSerieCertificado + "||"
+ End If
+
+ If Not ImagenCBB.Exists Then
+ Dim CBB As New ClbNegBICFDv3_2.ClsNegCBBGenerar()
+ CBB.GenerarCBB(UsuarioActual.Empresa.RFC, ClienteRFC, Total, FolioFiscal, RutaCBB)
+ End If
+
+ ImgCBB = String.Format("{0}://{1}:{2}/Empresas/{3}/CBB/Tra-{4}.jpg", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa, SerieFolio)
+ End If
+
+ If DtConceptos.Rows.Count > 0 Then
+ Dim params As New List(Of ReportParameter)
+ Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", UsuarioActual.Empresa.Ruta))
+ Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)
+ If Imagen.Exists Then
+ params.Add(New ReportParameter("LogoPath", logouri))
+ Else
+ params.Add(New ReportParameter("LogoPath", ""))
+ End If
+ 'EMPRESA
+ params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
+ params.Add(New ReportParameter("RegimenFiscal", UsuarioActual.Empresa.Regimen))
+ params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
+ params.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToShortDateString))
+ params.Add(New ReportParameter("DomicilioFiscal", $"{UsuarioActual.Empresa.Direccion}, {UsuarioActual.Empresa.Colonia}, {UsuarioActual.Empresa.Localidad}, {UsuarioActual.Empresa.Estado}, Tel. {Telefono}"))
+ params.Add(New ReportParameter("SerieFolio", SerieFolio))
+ params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
+ params.Add(New ReportParameter("DomicilioExpedicion", LugarExpedicion))
+ 'CLIENTE
+ params.Add(New ReportParameter("ClienteNombre", ClienteNombre))
+ params.Add(New ReportParameter("ClienteRFC", ClienteRFC))
+ params.Add(New ReportParameter("UsoCFDi", ClienteUsoCFDi))
+ 'TRANSPORTE
+ params.Add(New ReportParameter("MedioTransporte", MedioTransporte))
+ params.Add(New ReportParameter("TransporteInternacional", TransporteInternacional))
+ params.Add(New ReportParameter("PermisoSTCC", PermisoSTCC))
+ params.Add(New ReportParameter("NumPermiso", NumPermiso))
+ params.Add(New ReportParameter("Aseguradora", Aseguradora))
+ params.Add(New ReportParameter("NumPoliza", NumPolizaSeguro))
+ params.Add(New ReportParameter("PlacaVM", PlacaVM))
+ params.Add(New ReportParameter("AnioVM", AnioModeloVM))
+ 'TIMBRADO
+ params.Add(New ReportParameter("FolioFiscal", FolioFiscal))
+ params.Add(New ReportParameter("QR", ImgCBB))
+ params.Add(New ReportParameter("SelloCFDI", SelloCFDi))
+ params.Add(New ReportParameter("CertificadoContribuyente", NoCertificadoSAT))
+ params.Add(New ReportParameter("CadenaOriginal", CadenaOriginal))
+ params.Add(New ReportParameter("SerieCertificadoSAT", NoSerieCertificado))
+ params.Add(New ReportParameter("FechaCertificacion", FechaCertificacion.ToString("dd/MM/yyyy HH:mm:ss")))
+ params.Add(New ReportParameter("SelloSAT", SelloSAT))
+ 'TOTALES
+ params.Add(New ReportParameter("SubTotal", SubTotal.ToString()))
+ params.Add(New ReportParameter("Descuentos", Descuentos.ToString()))
+ params.Add(New ReportParameter("Total", Total.ToString()))
+ ' [@CertificadoContribuyente]
+ '[@CadenaOriginal]
+
+ Dim lrds As New List(Of ReportDataSource)
+
+ Dim rds As New ReportDataSource
+ rds.Name = "DataSet1"
+ rds.Value = DtConceptos
+ lrds.Add(rds)
+
+ Dim rds2 As New ReportDataSource
+ rds2.Name = "DataSet2"
+ rds2.Value = DtUbicaciones
+ lrds.Add(rds2)
+
+ Dim rds3 As New ReportDataSource
+ rds3.Name = "DataSet3"
+ rds3.Value = DtMercancias
+ lrds.Add(rds3)
+
+ Dim rds4 As New ReportDataSource
+ rds4.Name = "DataSet4"
+ rds4.Value = DtOperadores
+ lrds.Add(rds4)
+
+ ImprimirPDF("Empresas/Grales/Formatos/CartaPorteTimbrado.rdlc", lrds, params, String.Format("Carta Porte -{0}", Now.ToDateTime.ToShortDateString))
+ End If
+ End If
+ End Sub
+
#End Region
#Region "OP = 'DesXmlTra' - IMPRIME XML TRASLADO"
diff --git a/Empresas/Grales/Formatos/CartaPorteTimbrado.rdlc b/Empresas/Grales/Formatos/CartaPorteTimbrado.rdlc
new file mode 100644
index 000000000..24d09caea
--- /dev/null
+++ b/Empresas/Grales/Formatos/CartaPorteTimbrado.rdlc
@@ -0,0 +1,3627 @@
+
+