Attribute VB_Name = "Module1"
Public CN As New ADODB.Connection
Public comando As ADODB.Command
Public queryInsert As String
Public CN2 As New ADODB.Connection
Public rs1 As New ADODB.Recordset
Public rs2 As New ADODB.Recordset
Public rs3 As New ADODB.Recordset
Public rs4 As New ADODB.Recordset
Public rs5 As New ADODB.Recordset
Public rs6 As New ADODB.Recordset
Public rs7 As New ADODB.Recordset
Public rs8 As New ADODB.Recordset
Public rs9 As New ADODB.Recordset
Public rs10 As New ADODB.Recordset
Public rsMoneda As New ADODB.Recordset
Public rsIdioma As New ADODB.Recordset
Public vNroSerial As String
Public vSerial2 As String
Public vSerial3 As String
Public vUsaSerial As Boolean
Public vDesactivarActChange As Boolean
Public vEditarColumnas As Boolean
Public vTablaEditarCol As String
Public vCondicionesWeb As String
Public vCondicionesWeb2 As String
Public vFactorEspecial As Boolean
Public vFactorOtro As Boolean
Public vClienteDirectoWP As Boolean
Public vTodoEnBulto As Boolean
Public vPrecioUnidadAuto As Boolean
Public vBloquearFacturarN As Boolean
Public vMySqlQuery As String
Public vCONFIGURACION As String
Public vVentasDetalladas As String
Public vSeniatActivo As Boolean

Public vInvInsuficiente As Boolean

Public vLIMITE_ESTACION As Long

Public vDetalleServicio As String

Public vLogoAct As String
Public vImpresoraSP As String
Public vSerie02 As String
Public vSerie03 As String
Public vDesactivarChange As Boolean

Public vLimiteBs As Double
Public vLimiteTPM As String
Public vDesactivarOperacionAuto As Boolean
Public vDescripcionExtendida As String

Public vSpoolerTipo As String
Public vSpoolerPuerto As String
Public vSpoolerInterno As String
Public vNumeroDSP As String
Public vTipoDSP As String
Public rs8SP As New ADODB.Recordset
Public rs3SP As New ADODB.Recordset
Public rs4SP As New ADODB.Recordset
Public rs5SP As New ADODB.Recordset
Public rs6SP As New ADODB.Recordset
Public rs9SP As New ADODB.Recordset
Public rs10SP As New ADODB.Recordset
Public rsVerCodigo As New ADODB.Recordset
Public rsCombo As New ADODB.Recordset
Public rsFac As New ADODB.Recordset
Public rsCob As New ADODB.Recordset
Public rsClie As New ADODB.Recordset
Public rsClieCXC As New ADODB.Recordset
Public MENSAJE_321 As String
Public CONEXION_D As String
Public EXECUTE_D As String
Public vTabla As String
Public V_Vista As String
Public NOMBRE_PC_ID As String
Public DIRECCION_PC_IP As String
Public dbindEx As Integer
Public vClienteSeleccion As Boolean
Public vGuardarDoc As Boolean
Public vVendedorSelec As Boolean
Public vZonaSelec As Boolean
Public vDepositoSelec As Boolean
Public vCodClie As String
Public vNomClie As String
Public vDirec1 As String
Public vDirec2 As String
Public vTelef As String
Public vSaldo As Double
Public vEsCredito As String
Public vCodProd As String
Public vNomProd As String
Public vEsExento As String
Public vPrecio3 As Double
Public vPrecio2 As Double
Public vPrecio1 As Double
Public vFinalizarFac As Boolean
Public vProductoSelec As Boolean
Public vMediosPagoSelec As Boolean
Public vCargarSelec As Boolean
Public vCargarNumero As String
Public vCargarTipo As String
Public vNivel As Long
Public vCodVend As String
Public vCodVendInicial As String
Public vNomVend As String
Public vCodDepo As String
Public vNomDepo As String
Public vFactor As Double
Public vPrecioSel As String
Public vAutorizar As Boolean
Public vAutorizarFac As Boolean
Public vProdRow As Long
Public vValorPre As Double
Public vPrecioAcep As Boolean
Public vCodEsta As String
Public vCodUsua As String
Public vUltPrecio As Double
Public vIva As Double
Public vCodTaxs As String
Public vImpuesto As Double
Public vTotImpuesto As Double
Public vTotGravable As Double
Public vTotExento As Double
Public vRowMP As Long
Public vColMP As Long
Public vTotProd As Double
Public vTotServ As Double
Public vUltDocEsp As String
Public vPagoDirecto As String
Public vAdvertirExistencia As Boolean
Public vCantidadDirecto As Boolean
Public vClienteDirecto As String
Public vPrecioDirecto As String
Public vCantEntBarra As Long
Public vCantDecBarra As Long
Public vCantBarra As Double
Public vTipoFacTotal As String
Public vFinalizarCobro As Boolean
Public vNivelInicial As Long
Public vSaldoClienteTemp As Double
Public vSaldoAnticipo As Double
Public vPrecioDefault As String
Public vRifENC As String
Public vDescripENC As String
Public vRife As String
Public vDescripE As String
Public vDirec1E As String
Public vDirec2E As String
Public vDirec3E As String
Public vDirec4E As String
Public vImpresoraE As String
Public vSoloDolar As String
Public vACTUALIZAR_PROD_FACTOR As String
Public vDiasVencido As Double
Public vPrecioTitulo As String
Public vExistenciaNegativa As String

Public vFiltroExisten As String
Public vFiltroFalla As String
Public vUsuarioFactor As String
Public vUsuarioPCVend As String
Public vBulto As Boolean
Public vDescripBultoUnd As String
Public vImprimirFormato As String
Public vImprimirDocEspera As String
Public vDescuentoP As Double
''''''''''''''DESCUENTO
Public vTotDescP As Double
Public vPorDescP As Double
Public vMtoDescP As Double
Public vTotPagP As Double
Public vIdioma As Integer
Public vGuardarPresupuesto As Boolean
Public vReconectarNumero As String
Public vPagoMovilTelefono As String
Public vPagoMovilCedula As String
Public vPagoMovilBanco As String
Public vPagoMovilMonto As Double
Public vPagoMovilRefere As String
Public vFuenteSize As String
Public vCodOperMatris() As String
Public vUsaBalanza As String
Public vBalanzaPuerto As String
Public vBalanzaModelo As String
Public vNroestable As String
Public vDiasVence As String
Public vPesoTot As Double
Public vVerificarCodigo As String
Public vTotCodVerificar() As String
Public vTotVerificar As Long
Public vTotProdInconsitencia As Long
Public vUsuaVend As String
Public vDiasCred As Long
Public vLimiteCred As Double
Public vTDiasCred As Double
Public vTotCred As Double
Public vUnificarPresupuesto As String
Public vImpPreDirecto As String
Public vProdEmpaque As String
Public vCodEmpaque As String
Public vReferePM As String
Public vMontoPM As Double
Public vIdPM As Long
Public vModificarPrecioServicio As String
Public vValidarRif As String
Public vAcceso As String
Public vMostrarFactor As String
Public vBoquearAdvertirExistencia As String
Public vTipoIva10 As Boolean
Public vUltAltura As Double
Public vDETALLE As String
Public vLOGO As String
Public vLIMITE As Double
Public vLIMITEt As Double
Public vMTOFF As Double
Public vEstaciones As String

Public vSerial As String
Public vCORTE As String
Public vAbrirGaveta As String
Public vControlFecha As String

Public vListaProdVerificar As String
Public vListaCodVer As String

Public vCopiaFact As String
Public vDetalleGrande As String
Public vTipoFacNota As String
Public vFactorD As Double
Public vFactorDS As String
Public vAbonoCliente As Double
Public vAbonoClienteS As String
Public vAbonoClienteT As Boolean
Public vTextoNota As String
Public vImprimirCopiaDolar As String
Public vIncluirIvaDolar As String
Public vRefeGrande As String
Public vFacturarJuridico As String
Public vFacturarObligado As String
Public vImpTotArticulo As String
Public vImpDolRef As String
Public VCODCOMBO As String
Public vNroPrecios As String
Public vSerieCorrelativo As String
Public vIGTF As String
Public vIGTF_TEMP As String
Public vIGTF_TEMP2 As String
Public vIGTFBASE As Double
Public VIGTFMONTO As String
Public vIGTFFAC As Double
Public vActivarTR As String
Public vBultoFactor As String
Public vValidarProducto As String
Public vZCorto As String
Public vFactorIndependiente As String
Public vDescripcionBusqueda As String
Public vDepositoInicial As String
Public vFactorProd As Double

Public vIdGen As Long
Public vNombreGen As String
Public vRifGen As String
Public vLoginGen As String
Public vClaveGen As String
Public vPaisGen As String
Public vEstadoGen As String
Public vSaldoGen As Double
Public vLicenciaGen As String
Public vFechaGen As String
Public vMacAddress As String
Public vActivarDesactivarIGTF As String
Public vActivarNotaEntrega As String
Public vBloquearPresupuesto As String
Public vVerificarPesoSalida As String
Public vTara As Double
Public vQrAct As String
Public vQrEspacio As String
Public vUsaBanco As String
Public vNotasPresupuesto As String
Public vNotasPres As String
Public VNotas6 As String
Public vInventarioComprometido As String
Public vCod As String
Public vCodigoEnFactura As String
Public vDescuentoConvenio As Double
Public vDescuentoEspecial As Double
Public vDescuentoConvenioS As String
Public vDescuentoEspecialS As String
Public vDESCTO2 As String
Public vDESCTO1 As String
Public vDescto2N As Double
Public vDescto1N As Double
Public vMontoParaDesc As Double
Public vSERIALTEMP As String
Public vLimiteLineas As Long
Public vServidorFTP As String
Public vUsuarioFTP As String
Public vClaveFtp As String
Public vRutaFTP As String
Public INTERNET_DEFAULT_FTP_PORT As Long
Public vPendienteElimiarPedidoWeb As String
Public vRutaImagen As String
Public vRutaImagenActiva As Boolean
Public vRutaDescrip3 As String
Public vRutaSDescrip3 As String
Public AcWebTodo As Long
Public vPrecioTODO As String
Public vNroCopias As String
Public vDescuentoGeneral As Double
Public VDescuentoParcial As Double
Public vDiasCreditoUsua As Long
Public vDiasToleranciaUsua As Long
Public vDiasCreditoPendiente As Long
Public vMontoCreditoPendiente As Double
Public vExistenciaNegativaUsua As Long
Public vBloquearbulto As Long

Public vMostrarMonedaEspecifica As String
Public vFactorMonedaEspecifica As Double
Public vCambiarTamCol As Boolean
Public vDescripBusquedaFiltro As String
Public vFiltroIniSql As String
Public vCancelarEdicion As Boolean
Public vCancelarTecnico As Boolean
Public vDetalleFac2 As String
Public vDetalleFac3 As String
Public vDetalleFac4 As String
Public vDetalleFac5 As String
Public vDetalleFac6 As String
Public vDetalleFac7 As String
Public vDetalleFac8 As String
Public vDetalleFac9 As String
Public vDetalleFac10 As String
Public vLogisticaActivo As Boolean
Public vVehiculoActivo As Boolean
Public vUsaEnviosLogistica As Boolean
Public vTablaBusqueda As String
Public vCamposBusqueda As String
Public vValorBusqueda As String
Public vFiltroBusqueda As String
Public vAceptarBusqueda As Boolean
Public vTablaTamanio As Long
Public vJson As Boolean
Public vJsonRuta As String
Public vJsonArchivo As String
Public vSubirSinExistencia As String

Public Function QuitarCaracteresEspeciales(ByVal Cadena As String) As String
    Dim resultado As String
    Dim i As Integer
    Dim ch As String * 1
    Dim CarE As String

    resultado = ""
    
    For i = 1 To Len(Cadena)
        ch = Mid(Cadena, i, 1)
        CarE = Asc(Mid(Cadena, i, 1))
        If ch = vbTab Then
            ch = " "
        End If
        If CarE = 13 Then
            ch = " "
        End If
        If CarE = 10 Then
            ch = " "
        End If
        ' Verificar si el carácter es alfanumérico (A-Z, a-z, 0-9)
        If (ch >= "A" And ch <= "Z") Or (ch >= "a" And ch <= "z") Or (ch >= "0" And ch <= "9") Or (ch = "(") Or (ch = ")") Or (ch = "'") Or (ch = "_") Or (ch = ",") Or (ch = ".") Or (ch = " ") Then
            resultado = resultado & ch
        Else
            'MsgBox (CarE)
        End If
    Next i
    
    QuitarCaracteresEspeciales = resultado
End Function
Sub BloquearUsuario()
V_Vista = "SELECT   * FROM   SSUSRS WHERE    (codusua = '" & vCodUsua & "')"
ActualizarRs7
If rs7.EOF = False Then
    vAcceso = rs7.Fields("ACCESO").Value
    vNivel = rs7.Fields("Movil").Value
    VDescuentoParcial = rs7.Fields("DescuentoParcial").Value
    vDescuentoGeneral = rs7.Fields("DescuentoGeneral").Value
    vDiasCreditoUsua = rs7.Fields("DiasCredito").Value
    vDiasToleranciaUsua = rs7.Fields("DiasTolerancia").Value
    vExistenciaNegativaUsua = rs7.Fields("ExistenciaNegativa").Value
    vBloquearbulto = rs7.Fields("BloquearBulto").Value
    If IsNull(rs7.Fields("UsrDta1").Value) = False Then
        vUsuarioFactor = rs7.Fields("USRDTA1").Value
    Else
        vUsuarioFactor = ""
    End If
End If
End Sub

Public Sub EncabeGeneral()
Printer.FontSize = 8
'Printer.Font = "Lucida Console"
Printer.FontItalic = False
Printer.FontBold = False

Printer.Print vRife
If vLOGO = "SI" Then
vUltAltura = Printer.CurrentY
Call Imprimir_Imagen(FRMFISCAL.Picture1.Picture, 1 * 0.5)
Printer.Print " "
Printer.Print " "
Printer.Print " "
Printer.Print " "
Printer.Print " "
Printer.Print " "
End If

Printer.Print vDescripE
Printer.FontSize = 7

Printer.Print vDirec1E
Printer.Print vDirec2E
Printer.Print vDirec3E
Printer.Print vDirec4E

End Sub

Public Sub Imprimir_Imagen(pic As StdPicture, ZOOM As Double)
  Printer.Print
  
  'Dibujamos la imagen multiplicando el ancho y alto por el valor del ZOOM
  Printer.PaintPicture pic, 0, vUltAltura, pic.Width * ZOOM, _
                       pic.Height * ZOOM, 0, 0, pic.Width, _
                       pic.Height
  
  'Mandamos a imprimir la imagen
  'Printer.EndDoc
End Sub
Public Function NumeroValor(valor As Variant) As Double
Dim Monto As Double
Dim VNUM() As String


If IsNumeric(valor) = True Then
    If InStr(1, valor, ",") >= 1 Then
        'MsgBox ("TIENE COMA")
        Monto = Replace(valor, ".", "")
    Else
        'MsgBox ("NO TIENE COMA")
        VNUM() = Split(valor, ".")
        'MsgBox (UBound(VNUM))
        If UBound(VNUM) = 1 Then
            Monto = Replace(valor, ".", ",")
        Else
            Monto = valor
        End If
    End If
    
    NumeroValor = Monto
    
Else
    NumeroValor = "0"
    
End If
    
End Function

Public Sub ActualizarRs1()

Set rs1 = New ADODB.Recordset
On Error Resume Next
    With rs1
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 1
    Desconectar
    Conectar
    Reconectar
End If

End Sub


Public Sub ActualizarRs2()

Set rs2 = New ADODB.Recordset
On Error Resume Next
    With rs2
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With

If Err.Description <> "" Then
    vReconectarNumero = 2
    Desconectar
    Conectar
    Reconectar
End If
End Sub
Sub Desconectar()
    CN.Close
End Sub
Sub Conectar()
    CN.Open CONEXION_D
End Sub
Sub Reconectar()
    MEN123 = MsgBox("Hubo una Desconexion o Actualizacion en la Red, Desea Actualizar ?", vbYesNo)
    If MEN123 = vbYes Then
        Select Case vReconectarNumero
            Case 1
                ActualizarRs1
            Case 2
                ActualizarRs2
            Case 3
                ActualizarRs3
            Case 4
                ActualizarRs4
            Case 5
                ActualizarRs5
            Case 6
                ActualizarRs6
            Case 7
                ActualizarRs7
            Case 8
                ActualizarRs8
            Case "FAC"
                ActualizarRsFac
            Case "CLIE"
                ActualizarRsClie
            Case "CXC"
                ActualizarRsClieCXC
            Case "COMBO"
                ActualizarRsCOMBO
        End Select
    End If
End Sub

Public Sub ActualizarRs3()

Set rs3 = New ADODB.Recordset
On Error Resume Next
    With rs3
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 3
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs3SP()

Set rs3SP = New ADODB.Recordset
On Error Resume Next
    With rs3SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub


Public Sub ActualizarRs4SP()

Set rs4SP = New ADODB.Recordset
On Error Resume Next
    With rs4SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

Public Sub ActualizarRs4()

Set rs4 = New ADODB.Recordset
On Error Resume Next
    With rs4
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then

    CN.Execute "UPDATE _C_ADICIONALES SET ORDENAR='DESCRIP'"
    vReconectarNumero = 4
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs5()

Set rs5 = New ADODB.Recordset
On Error Resume Next
    With rs5
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 5
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs5SP()

Set rs5SP = New ADODB.Recordset
On Error Resume Next
    With rs5SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

Public Sub ActualizarRs6SP()

Set rs6SP = New ADODB.Recordset
On Error Resume Next
    With rs6SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

Public Sub ActualizarRs6()

Set rs6 = New ADODB.Recordset
On Error Resume Next
    With rs6
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 6
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs7()

Set rs7 = New ADODB.Recordset
On Error Resume Next
    With rs7
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 7
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs8()

Set rs8 = New ADODB.Recordset
On Error Resume Next
    With rs8
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = 8
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRs8SP()

Set rs8SP = New ADODB.Recordset
On Error Resume Next
    With rs8SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN2, , , 1
    End With
'If Err.Description <> "" Then
'    vReconectarNumero = 8
'    Desconectar
'    Conectar
'    Reconectar
'End If

End Sub

Public Sub ActualizarRs9()

Set rs9 = New ADODB.Recordset
On Error Resume Next
    With rs9
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN2, , , 1
    End With
'If Err.Description <> "" Then
'    vReconectarNumero = 9
'    Desconectar
'    Conectar
'    Reconectar
'End If

End Sub
Public Sub ActualizarRs10()

Set rs10 = New ADODB.Recordset
On Error Resume Next
    With rs10
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
'If Err.Description <> "" Then
'    vReconectarNumero = 9
'    Desconectar
'    Conectar
'    Reconectar
'End If

End Sub

Public Sub ActualizarRs9SP()

Set rs9SP = New ADODB.Recordset
On Error Resume Next
    With rs9SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

Public Sub ActualizarRs10SP()

Set rs10SP = New ADODB.Recordset
On Error Resume Next
    With rs10SP
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

Public Sub ActualizarRsFac()

Set rsFac = New ADODB.Recordset
On Error Resume Next
    With rsFac
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = "FAC"
    Desconectar
    Conectar
    Reconectar
End If

End Sub


Public Sub ActualizarRsClie()

Set rsClie = New ADODB.Recordset
On Error Resume Next
    With rsClie
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = "CLIE"
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRsClieCXC()

Set rsClieCXC = New ADODB.Recordset
On Error Resume Next
    With rsClieCXC
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = "CXC"
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRsCOMBO()

Set rsCombo = New ADODB.Recordset
On Error Resume Next
    With rsCombo
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = "COMBO"
    Desconectar
    Conectar
    Reconectar
End If

End Sub


Public Sub ActualizarRsVerCodigo()

Set rsVerCodigo = New ADODB.Recordset
On Error Resume Next
    With rsVerCodigo
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With
If Err.Description <> "" Then
    vReconectarNumero = "COMBO"
    Desconectar
    Conectar
    Reconectar
End If

End Sub

Public Sub ActualizarRsIdioma()

Set rsIdioma = New ADODB.Recordset
On Error Resume Next
    With rsIdioma
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub


Public Sub ActualizarRsMoneda()

Set rsMoneda = New ADODB.Recordset
On Error Resume Next
    With rsMoneda
        .CursorLocation = adUseClient
        .CursorType = adOpenStatic
        .LockType = adLockBatchOptimistic
        .Open V_Vista, CN, , , 1
    End With


End Sub

