Este artículo se aplica a Microsoft Dynamics NAV para la configuración regional del idioma italiano (it).
Síntomas
Suponga que tiene una factura creada para un proveedor de la Unión Europea (UE) en la versión italiana de Microsoft Dynamics NAV 5.0 Service Pack 1 (SP1). Cuando se contabiliza un abono de tipo Cargo (artículo) para la factura en un período diferente, la línea de memorando de crédito no se incluye en el diario intrastat.
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 en el número 2 de elemento de datos del informe Obtener movimiento de artículos (594) de la siguiente manera:
Código 1 existente... ELSE SETRANGE("Entry Type","Entry Type"::Sale); IntrastatJnlLine2.SETCURRENTKEY("Source Type","Source Entry No."); IntrastatJnlLine2.SETRANGE("Source Type",IntrastatJnlLine2."Source Type"::"Item entry"); ...Código de reemplazo 1
... ELSE SETRANGE("Entry Type","Entry Type"::Sale); // Add the following line. IntrastatJnlLine2.SETRANGE("Journal Batch Name",IntrastatJnlBatch.Name); IntrastatJnlLine2.SETCURRENTKEY("Source Type","Source Entry No."); IntrastatJnlLine2.SETRANGE("Source Type",IntrastatJnlLine2."Source Type"::"Item entry"); ...Código 2 existente
... END; OnAfterGetRecord=VAR // Delete the following lines. SalesShipmentLine@1005 : Record 111; ReturnReceiptLine@1004 : Record 6661; PurchRcptLine@1003 : Record 121; ReturnShipmentLine@1002 : Record 6651; ServiceShipmentLine@1001 : Record 5991; ServiceCrMemoLine@1000 : Record 5995; // End of the lines. PurchInvLine@1130000 : Record 123; PurchCrMemoLine@1130001 : Record 125; SalesInvoiceLine@1130002 : Record 113; ...Código de reemplazo 2
... END; OnAfterGetRecord=VAR // Add the following line. PurchRcptLine@1003 : Record 121; PurchInvLine@1130000 : Record 123; PurchCrMemoLine@1130001 : Record 125; SalesInvoiceLine@1130002 : Record 113; ...Código 3 existente
... SalesCrMemoHeader@1130005 : Record 114; PurchInvHeader@1130006 : Record 122; PurchCrMemoHdr@1130007 : Record 124; // Delete the following line. SalesShipmentHeader@1130008 : Record 110; SalesShipLine@1130019 : Record 111; ReturnRcptHeader@1130011 : Record 6660; DocItemSum@1130013 : Decimal; ...Código de reemplazo 3
... SalesCrMemoHeader@1130005 : Record 114; PurchInvHeader@1130006 : Record 122; PurchCrMemoHdr@1130007 : Record 124; SalesShipLine@1130019 : Record 111; ReturnRcptHeader@1130011 : Record 6660; DocItemSum@1130013 : Decimal; ...Código 4 existente
... IF IntrastatJnlLine2.FINDFIRST OR (CompanyInfo."Country/Region Code" = "Country/Region Code") THEN CurrReport.SKIP; // Delete the following lines. CASE TRUE OF "Document Type" = "Document Type"::"Sales Shipment": IF SalesShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(SalesShipmentLine."VAT Bus. Posting Group",SalesShipmentLine."VAT Prod. Posting Group") THEN; ("Document Type" = "Document Type"::"Sales Return Receipt") OR ("Document Type" = "Document Type"::"Sales Credit Memo"): IF ReturnReceiptLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ReturnReceiptLine."VAT Bus. Posting Group",ReturnReceiptLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Purchase Receipt": IF PurchRcptLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(PurchRcptLine."VAT Bus. Posting Group",PurchRcptLine."VAT Prod. Posting Group") THEN; ("Document Type" = "Document Type"::"Purchase Return Shipment") OR ("Document Type" = "Document Type"::"Purchase Credit Memo"): IF ReturnShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ReturnShipmentLine."VAT Bus. Posting Group",ReturnShipmentLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Service Shipment": IF ServiceShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ServiceShipmentLine."VAT Bus. Posting Group",ServiceShipmentLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Service Credit Memo": IF ServiceCrMemoLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ServiceCrMemoLine."VAT Bus. Posting Group",ServiceCrMemoLine."VAT Prod. Posting Group") THEN; END; IF VATPostingSetup."EU Service" THEN CurrReport.SKIP; IF ("Entry Type" = "Entry Type"::Sale) AND (SalesShipmentHeader.GET("Document No.")) AND (CompanyInfo."Country/Region Code" = SalesShipmentHeader."Bill-to Country/Region Code") THEN CurrReport.SKIP; // End of the lines. TotalInvoicedQty := 0; TotalAmt := 0; ...Código de reemplazo 4
... IF IntrastatJnlLine2.FINDFIRST OR (CompanyInfo."Country/Region Code" = "Country/Region Code") THEN CurrReport.SKIP; // Add the following line. TestILE("Item Ledger Entry"); TotalInvoicedQty := 0; TotalAmt := 0; ...Cambie el código en el número 5 de elemento de datos del informe Obtener movimiento de artículos (594) de la siguiente manera:
Código existente... { } } } REQUESTFORM { ...Código de reemplazo
... { } } // Add the following lines. { PROPERTIES { DataItemTable=Table5802; DataItemTableView=SORTING(Entry No.); OnPreDataItem=BEGIN SETRANGE("Posting Date",StartDate,EndDate); SETFILTER("Item Charge No.",'<> %1',''); "Item Ledger Entry".SETRANGE("Posting Date"); IF IntrastatJnlBatch.Type = IntrastatJnlBatch.Type::Purchases THEN SETFILTER("Item Ledger Entry Type",'%1|%2', "Item Ledger Entry Type"::Purchase, "Item Ledger Entry Type"::Transfer) ELSE SETRANGE("Item Ledger Entry Type","Item Ledger Entry Type"::Sale); IntrastatJnlLine2.SETRANGE("Journal Batch Name",IntrastatJnlBatch.Name); IntrastatJnlLine2.SETCURRENTKEY("Source Type","Source Entry No."); IntrastatJnlLine2.SETRANGE("Source Type",IntrastatJnlLine2."Source Type"::"Item entry"); END; OnAfterGetRecord=BEGIN IntrastatJnlLine2.SETRANGE("Source Entry No.","Item Ledger Entry No."); IF IntrastatJnlLine2.FINDFIRST THEN CurrReport.SKIP; IF "Item Ledger Entry".GET("Item Ledger Entry No.") THEN BEGIN IF ("Item Ledger Entry"."Posting Date" > StartDate) AND ("Item Ledger Entry"."Posting Date" < EndDate) THEN CurrReport.SKIP; IF "Country/Region".GET("Item Ledger Entry"."Country/Region Code") THEN IF "Country/Region"."EU Country/Region Code" = '' THEN CurrReport.SKIP; TestILE("Item Ledger Entry"); InsertValueEntryLine; END; END; } SECTIONS { { PROPERTIES { SectionType=Body; SectionWidth=12000; SectionHeight=846; } CONTROLS { } } } } // End of the lines. } REQUESTFORM { ...Cambie el código en la documentación del informe Obtener movimiento de artículos (594) como se indica a continuación:
Código existente... IntrastatJnlBatch2.SETRANGE(Type,IntrastatJnlBatch.Type); END; BEGIN END. } RDLDATA ...Código de reemplazo
... IntrastatJnlBatch2.SETRANGE(Type,IntrastatJnlBatch.Type); END; // Add the following lines. PROCEDURE TestILE@1130001(ItemLedgEntry@1130000 : Record 32); VAR SalesShipmentHeader@1130001 : Record 110; SalesShipmentLine@1130002 : Record 111; PurchRcptLine@1130003 : Record 121; ReturnReceiptLine@1130004 : Record 6661; ReturnShipmentLine@1130005 : Record 6651; ServiceShipmentLine@1130006 : Record 5991; ServiceCrMemoLine@1130007 : Record 5995; BEGIN WITH ItemLedgEntry DO BEGIN CASE TRUE OF "Document Type" = "Document Type"::"Sales Shipment": IF SalesShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(SalesShipmentLine."VAT Bus. Posting Group",SalesShipmentLine."VAT Prod. Posting Group") THEN; ("Document Type" = "Document Type"::"Sales Return Receipt") OR ("Document Type" = "Document Type"::"Sales Credit Memo"): IF ReturnReceiptLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ReturnReceiptLine."VAT Bus. Posting Group",ReturnReceiptLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Purchase Receipt": IF PurchRcptLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(PurchRcptLine."VAT Bus. Posting Group",PurchRcptLine."VAT Prod. Posting Group") THEN; ("Document Type" = "Document Type"::"Purchase Return Shipment") OR ("Document Type" = "Document Type"::"Purchase Credit Memo"): IF ReturnShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ReturnShipmentLine."VAT Bus. Posting Group",ReturnShipmentLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Service Shipment": IF ServiceShipmentLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ServiceShipmentLine."VAT Bus. Posting Group",ServiceShipmentLine."VAT Prod. Posting Group") THEN; "Document Type" = "Document Type"::"Service Credit Memo": IF ServiceCrMemoLine.GET("Document No.","Document Line No.") THEN IF VATPostingSetup.GET(ServiceCrMemoLine."VAT Bus. Posting Group",ServiceCrMemoLine."VAT Prod. Posting Group") THEN; END; IF VATPostingSetup."EU Service" THEN CurrReport.SKIP; IF ("Entry Type" = "Entry Type"::Sale) AND (SalesShipmentHeader.GET("Document No.")) AND (CompanyInfo."Country/Region Code" = SalesShipmentHeader."Bill-to Country/Region Code") THEN CurrReport.SKIP; END; END; PROCEDURE InsertValueEntryLine@1130002(); VAR Location@1130000 : Record 14; BEGIN GetGLSetup; WITH IntrastatJnlLine DO BEGIN INIT; "Line No." := "Line No." + 10000; Date := "Value Entry"."Posting Date"; "Country/Region Code" := "Item Ledger Entry"."Country/Region Code"; "Transaction Type" := "Item Ledger Entry"."Transaction Type"; "Transport Method" := "Item Ledger Entry"."Transport Method"; "Source Entry No." := "Item Ledger Entry"."Entry No."; Quantity := "Item Ledger Entry".Quantity; "Document No." := "Value Entry"."Document No."; "Item No." := "Item Ledger Entry"."Item No."; "Entry/Exit Point" := "Item Ledger Entry"."Entry/Exit Point"; Area := "Item Ledger Entry".Area; "Transaction Specification" := "Item Ledger Entry"."Transaction Specification"; Amount := ROUND(ABS("Value Entry"."Sales Amount (Actual)"),1); IF Quantity < 0 THEN Type := Type::Shipment ELSE Type := Type::Receipt; IF ("Country/Region Code" = '') OR ("Country/Region Code" = CompanyInfo."Country/Region Code") THEN BEGIN IF "Item Ledger Entry"."Location Code" = '' THEN "Country/Region Code" := CompanyInfo."Ship-to Country/Region Code" ELSE BEGIN Location.GET("Item Ledger Entry"."Location Code"); "Country/Region Code" := Location."Country/Region Code" END; END; VALIDATE("Item No."); "Source Type" := "Source Type"::"Item entry"; VALIDATE(Quantity,ROUND(ABS(Quantity),0.00001)); VALIDATE("Cost Regulation %",IndirectCostPctReq); INSERT; END; END; // End of the lines. BEGIN END. } } ...
Requisitos previos
Debe tener la versión italiana de Microsoft Dynamics NAV 5.0 Service Pack 1 instalada para aplicar esta revisión.
Información sobre la eliminación
No puede quitar esta revisión.
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.