Este artículo se aplica a Microsoft Dynamics NAV para todos los países y todas las configuraciones regionales de idioma.
Síntomas
Suponga que hace clic para activar la casilla Advertencia de tolerancia de pago en el cuadro de diálogo Configuración de contabilidad general en Microsoft Dynamics NAV. Al registrar un diario de pago de cliente o un diario de pago de proveedor que tiene una tolerancia de descuento de pago y una tolerancia de pago, la cuenta de débito o la cuenta de crédito para la tolerancia de pago y los descuentos de pago se usan incorrectamente en los movimientos de contabilidad generales. En algunos casos, el importe de la tolerancia de pago se registra para la cuenta de débito aunque la cuenta de crédito se use en los movimientos de contabilidad generales.
Este problema se produce en los siguientes productos:
- Microsoft Dynamics NAV 2009 Service Pack 1 (SP1)
- Microsoft Dynamics NAV 2009
- Microsoft Dynamics NAV 5.0 Service Pack 1 (SP1)
- Microsoft Dynamics NAV 5,0
Resolución
Información de revisiones
Una revisión compatible ya está disponible en Microsoft. Sin embargo, solo está pensado para corregir el problema que se describe en este artículo. Aplicarlo solo a los sistemas que experimentan este problema específico. Esta revisión puede recibir pruebas adicionales. Por lo tanto, si no se ve afectado gravemente por este problema, le recomendamos que espere al siguiente Service Pack de Microsoft Dynamics NAV o a la siguiente versión de Microsoft Dynamics NAV que contenga esta revisión.
Nota En casos especiales, los cargos que se incurren normalmente por las llamadas de soporte técnico pueden cancelarse si un profesional de soporte técnico de Microsoft Dynamics y productos relacionados determina que una actualización específica resolverá el problema. Se aplicarán los costos habituales de soporte técnico a las consultas y cuestiones de soporte técnico adicionales que no guarden relación con la actualización en cuestión.
Información de instalación
Microsoft proporciona ejemplos de programación solo para ilustración, sin garantía expresa o implícita. Esto incluye, entre otras, las garantías implícitas de comerciabilidad o idoneidad para un propósito determinado. En este artículo se supone que está familiarizado con el lenguaje de programación que se muestra y con las herramientas que se usan para crear y depurar procedimientos. Los ingenieros de soporte técnico de Microsoft pueden explicarle la funcionalidad de un determinado procedimiento, pero no modificarán estos ejemplos para ofrecer mayor funcionalidad ni crearán procedimientos adaptados a sus necesidades específicas.
Nota Antes de instalar esta revisión, verifique que todos los usuarios cliente de Microsoft Navision hayan cerrado sesión en el sistema. Esto incluye a los usuarios cliente de Microsoft Navision Application Services (NAS). Usted debe ser el único usuario del cliente que ha iniciado sesión al implementar esta revisión.
Para implementar esta revisión, debe tener una licencia de desarrollador.
Le recomendamos que la cuenta de usuario en la ventana Inicios de sesión de Windows o en la ventana Inicios de sesión de base de datos tenga asignado el id. de rol "SUPER". Si no se puede asignar a la cuenta de usuario el id. de rol "SUPER", debe comprobar que la cuenta de usuario tiene los permisos siguientes:
- El permiso Modificar para el objeto que va a cambiar.
- El permiso Execute para el objeto System Object ID 5210 y para el objeto System Object ID 9015.
Nota No es necesario tener derechos sobre los almacenes de datos a menos que tenga que realizar una reparación de datos.
Cambios de código
Nota Pruebe siempre las correcciones de código en un entorno controlado antes de aplicar las correcciones a los equipos de producción.
Para resolver este problema, siga estos pasos:
Cambie el código de la función PostDtldVendLedgEntries en gen. Jnl.-Unidades de código de línea de poste (12) de la siguiente manera:
Código 1 existente… DtldCVLedgEntryBuf."Entry Type"::"Payment Discount Tolerance": BEGIN IF GLSetup."Pmt. Disc. Tolerance Posting" = GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Tolerance Accounts" THEN BEGIN IF (DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Credit Acc."; END; END ELSE IF GLSetup."Pmt. Disc. Tolerance Posting" = GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Discount Accounts" THEN BEGIN IF (DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Credit Acc."; …Código de reemplazo 1
… DtldCVLedgEntryBuf."Entry Type"::"Payment Discount Tolerance": BEGIN IF GLSetup."Pmt. Disc. Tolerance Posting" = GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Tolerance Accounts" THEN BEGIN IF (-DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Credit Acc."; END; END ELSE IF GLSetup."Pmt. Disc. Tolerance Posting" = GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Discount Accounts" THEN BEGIN IF (-DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Credit Acc."; …Código 2 existente
… DtldCVLedgEntryBuf."Entry Type"::"Payment Tolerance": BEGIN IF GLSetup."Payment Tolerance Posting" = GLSetup."Payment Tolerance Posting"::"Payment Tolerance Accounts" THEN BEGIN IF (DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Credit Acc."; END; END ELSE IF GLSetup."Payment Tolerance Posting" = GLSetup."Payment Tolerance Posting"::"Payment Discount Accounts" THEN BEGIN IF (DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Credit Acc."; …Código de reemplazo 2
… DtldCVLedgEntryBuf."Entry Type"::"Payment Tolerance": BEGIN IF GLSetup."Payment Tolerance Posting" = GLSetup."Payment Tolerance Posting"::"Payment Tolerance Accounts" THEN BEGIN IF (-DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Tolerance Credit Acc."; END; END ELSE IF GLSetup."Payment Tolerance Posting" = GLSetup."Payment Tolerance Posting"::"Payment Discount Accounts" THEN BEGIN IF (-DtldCVLedgEntryBuf."Amount (LCY)" >= 0) THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); PaymentTolAcc := VendPostingGr."Payment Disc. Credit Acc."; …Cambie el código de la función AutoEntrForDtldVendLedgEntries de la generación. Jnl.-Unidades de código de línea de poste (12) de la siguiente manera:
Código 1 existente… DtldCVLedgEntryBuf."Entry Type"::"Payment Discount Tolerance": BEGIN CASE GLSetup."Pmt. Disc. Tolerance Posting" OF GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Tolerance Accounts": BEGIN IF DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); AccNo := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); AccNo := VendPostingGr."Payment Tolerance Credit Acc."; END; END; GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Discount Accounts": BEGIN IF DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); AccNo := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); AccNo := VendPostingGr."Payment Disc. Credit Acc."; …Código de reemplazo 1
… DtldCVLedgEntryBuf."Entry Type"::"Payment Discount Tolerance": BEGIN CASE GLSetup."Pmt. Disc. Tolerance Posting" OF GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Tolerance Accounts": BEGIN IF -DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); AccNo := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); AccNo := VendPostingGr."Payment Tolerance Credit Acc."; END; END; GLSetup."Pmt. Disc. Tolerance Posting"::"Payment Discount Accounts": BEGIN IF -DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); AccNo := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); AccNo := VendPostingGr."Payment Disc. Credit Acc."; …Código 2 existente
… DtldCVLedgEntryBuf."Entry Type"::"Payment Tolerance": BEGIN CASE GLSetup."Payment Tolerance Posting" OF GLSetup."Payment Tolerance Posting"::"Payment Tolerance Accounts": BEGIN IF DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); AccNo := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); AccNo := VendPostingGr."Payment Tolerance Credit Acc."; END; END; GLSetup."Payment Tolerance Posting"::"Payment Discount Accounts": BEGIN IF DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); AccNo := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); AccNo := VendPostingGr."Payment Disc. Credit Acc."; …Código de reemplazo 2
… DtldCVLedgEntryBuf."Entry Type"::"Payment Tolerance": BEGIN CASE GLSetup."Payment Tolerance Posting" OF GLSetup."Payment Tolerance Posting"::"Payment Tolerance Accounts": BEGIN IF -DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Debit Acc."); AccNo := VendPostingGr."Payment Tolerance Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Tolerance Credit Acc."); AccNo := VendPostingGr."Payment Tolerance Credit Acc."; END; END; GLSetup."Payment Tolerance Posting"::"Payment Discount Accounts": BEGIN IF -DtldCVLedgEntryBuf."Amount (LCY)" < 0 THEN BEGIN VendPostingGr.TESTFIELD("Payment Disc. Debit Acc."); AccNo := VendPostingGr."Payment Disc. Debit Acc."; END ELSE BEGIN VendPostingGr.TESTFIELD("Payment Disc. Credit Acc."); AccNo := VendPostingGr."Payment Disc. Credit Acc."; …
Requisitos previos
Debe tener uno de los siguientes productos instalados para aplicar esta revisión:
- Microsoft Dynamics NAV 2009 Service Pack 1 (SP1)
- Microsoft Dynamics NAV 2009
- Microsoft Dynamics NAV 5.0 Service Pack 1 (SP1)
- Microsoft Dynamics NAV 5,0
Información sobre la eliminación
No puede quitar esta revisión.
Para obtener más información, haga clic en el número de artículo siguiente para verlo en Microsoft Knowledge Base:
981697 Se usa una cuenta de mayor incorrecta al registrar un pago para aplicar una factura en la que se usó "IVA completo" si la opción "Ajustar el descuento de pago" está habilitada en el formulario "Configuración de contabilidad general" en Microsoft Dynamics NAV 2009
Estado
Microsoft ha confirmado que se trata de un problema de los productos de Microsoft que se enumeran en la sección "Aplicable a".
Nota Esto es un artículo "PUBLICACIÓN RÁPIDA" creado directamente desde la organización de soporte técnico de Microsoft. La información contenida se proporciona tal cual en respuesta a nuevos problemas. Como resultado de la rapidez en la publicación, es posible que los materiales incluyan errores tipográficos. Además, se pueden revisar en cualquier momento sin previo aviso. Consulte los Términos de uso para otras consideraciones.