Bỏ qua để tới nội dung chính
Đăng nhập với Microsoft
Đăng nhập hoặc tạo một tài khoản.
Xin chào,
Chọn một tài khoản khác.
Bạn có nhiều tài khoản
Chọn tài khoản bạn muốn đăng nhập.

Bài viết này áp dụng cho Microsoft quốc gia và ngôn ngữ.

  • Tiếng Anh (Canada) (en-ca)

  • Tiếng Anh (Mỹ) (en-chúng tôi)

  • Tiếng Tây Ban Nha (Mexico) (es-mx)

  • Tiếng Pháp (Canada) (fr-ca)

Triệu chứng

Giả sử rằng bạn đặt CAD là giá trị tiền tệ báo cáo bổ sung trong thiết lập sổ cái chung hộp thoại Bắc Mỹ phiên bản của Microsoft Dynamics NAV 2009. Khi bạn gửi một đơn mua hàng có thuế, bạn nhận được thông báo lỗi sau:

Giao dịch không thể hoàn tất vì nó sẽ gây ra sự thiếu nhất quán trong bảng G/L mục. Kiểm tra vị trí và cách chức năng phù hợp được sử dụng trong giao dịch để tìm nguyên nhân gây ra lỗi.

Sự cố này xảy ra trong các sản phẩm sau:

  • Phiên bản Microsoft Dynamics NAV 2009 R2 Bắc Mỹ

  • Phiên bản Bắc Mỹ của Microsoft Dynamics NAV 2009 Service Pack 1


Giải pháp

Thông tin về cập nhật nóng

Microsoft hiện đã cung cấp bản cập nhật nóng được hỗ trợ. Tuy nhiên, nó chỉ được dùng để khắc phục sự cố được mô tả trong bài viết này. Áp dụng cho các hệ thống đang gặp sự cố cụ thể này. Hotfix này có thể được kiểm tra thêm. Vì vậy, nếu bạn không bị ảnh hưởng bởi sự cố này, chúng tôi khuyến nghị bạn đợi cho gói dịch vụ tiếp theo của Microsoft Dynamics NAV 2009 hoặc phiên bản Microsoft Dynamics NAV tiếp theo có chứa hotfix này.

Lưu ý Trong trường hợp đặc biệt, chi phí thường phát sinh để hỗ trợ cuộc gọi có thể được hủy bỏ nếu chuyên viên hỗ trợ kỹ thuật cho Microsoft Dynamics và sản phẩm liên quan xác định rằng một Cập Nhật cụ thể sẽ giải quyết vấn đề của bạn. Chi phí hỗ trợ thông thường sẽ áp dụng cho các vấn đề không phù hợp với bản Cập Nhật cụ thể trong câu hỏi và câu hỏi hỗ trợ bổ sung.



Thông tin cài đặt

Microsoft cung cấp mô hình lập trình để minh hoạ, không bảo hành hoặc rõ ràng hay ngụ ý. Điều này bao gồm, nhưng không giới hạn ở các bảo đảm cho một mục đích cụ thể hoặc sự. Bài viết này giả định rằng bạn đã quen với ngôn ngữ lập trình đang được giải thích và các công cụ được sử dụng để tạo và quy trình gỡ lỗi. Các kỹ sư hỗ trợ Microsoft có thể giúp giải thích các chức năng của một quy trình cụ thể, nhưng chúng sẽ không sửa đổi các ví dụ để cung cấp thêm chức năng hoặc xây dựng quy trình nhằm đáp ứng các yêu cầu cụ thể của bạn.

Lưu ý Trước khi cài đặt hotfix này, xác minh rằng tất cả Microsoft Navision khách người dùng đăng xuất hệ thống. Điều này bao gồm Microsoft Navision ứng dụng dịch vụ (NAS) khách người dùng. Bạn nên khách hàng chỉ người được đăng nhập khi bạn áp dụng hotfix này.

Để áp dụng hotfix này, bạn phải có giấy phép nhà phát triển.

Chúng tôi khuyên bạn nên tài khoản người dùng trong cửa sổ thông tin đăng nhập Windows hoặc trong cửa sổ thông tin đăng nhập cơ sở dữ liệu được gán vai trò "Siêu" của bạn. Nếu tài khoản người dùng không thể gán vai trò "SUPER" ID, bạn phải xác minh rằng tài khoản người dùng có các quyền sau đây:

  • Thay đổi quyền cho các đối tượng mà bạn sẽ thay đổi.

  • Quyền thực thi các đối tượng hệ thống đối tượng ID 5210 và các đối tượng hệ thống đối tượng ID 9015 .



Lưu ý Bạn không cần phải có quyền để lưu trữ dữ liệu nếu bạn phải tiến hành sửa chữa dữ liệu.

Thay đổi mã

Lưu ý Luôn kiểm tra mã khắc phục trong một môi trường được kiểm soát trước khi bạn áp dụng bản vá để sản xuất máy tính của bạn.

Để khắc phục sự cố này, hãy làm theo các bước sau:

  1. Thay đổi mã trong lĩnh vực trong bảng thuế bán hàng số dòng (10011) như sau:
    Mã hiện tại

    ...ESM=Es Informe jurisdicci¢n;
    FRC=Est une juridiction fiscale;
    ENC=Is Report-to Jurisdiction];
    Editable=No }
    }
    KEYS
    {
    { ;Tax Area Code for Key,Tax Jurisdiction Code,Tax %,Tax Group Code,Expense/Capitalize,Tax Type,Use Tax;
    ...

    Thay thế mã

    ...
    ESM=Es Informe jurisdicci¢n;
    FRC=Est une juridiction fiscale;
    ENC=Is Report-to Jurisdiction];
    Editable=No }

    // Add the following line.
    { 10044; ;Tax Base Amount FCY ;Decimal }
    // End of the added line.

    }
    KEYS
    {
    { ;Tax Area Code for Key,Tax Jurisdiction Code,Tax %,Tax Group Code,Expense/Capitalize,Tax Type,Use Tax;
    ...
  2. Thay đổi mã trong hàm PostSalesTaxToGL Codeunit bán hàng bài (80) như sau:
    Mã hiện tại

    ...END;
    GenJnlLine."Tax Jurisdiction Code" := TempSalesTaxAmtLine."Tax Jurisdiction Code";
    IF TempSalesTaxAmtLine."Tax Amount" <> 0 THEN BEGIN
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt +

    // Delete the following lines.
    CurrExchRate.ExchangeAmtLCYToFCY(
    UseDate,SalesHeader."Currency Code",TempSalesTaxAmtLine."Tax Amount",SalesHeader."Currency Factor");
    // End of the deleted lines.

    GenJnlLine."Source Curr. VAT Amount" :=
    SalesTaxCalculate.ArithmeticRound(RemSalesTaxSrcAmt,Currency."Amount Rounding Precision");
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt - GenJnlLine."Source Curr. VAT Amount";
    RemSalesTaxAmt := RemSalesTaxAmt + TempSalesTaxAmtLine."Tax Amount";
    ...

    Thay thế mã

    ...END;
    GenJnlLine."Tax Jurisdiction Code" := TempSalesTaxAmtLine."Tax Jurisdiction Code";
    IF TempSalesTaxAmtLine."Tax Amount" <> 0 THEN BEGIN
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt +

    // Add the following lines.
    TempSalesTaxAmtLine."Tax Base Amount FCY" * TempSalesTaxAmtLine."Tax %" / 100;
    // End of the added lines.

    GenJnlLine."Source Curr. VAT Amount" :=
    SalesTaxCalculate.ArithmeticRound(RemSalesTaxSrcAmt,Currency."Amount Rounding Precision");
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt - GenJnlLine."Source Curr. VAT Amount";
    RemSalesTaxAmt := RemSalesTaxAmt + TempSalesTaxAmtLine."Tax Amount";
    ...
  3. Thay đổi mã trong hàm PostSalesTaxToGL Purch.-bài Codeunit (90) như sau:
    Mã hiện tại

    ...END;
    GenJnlLine."Tax Jurisdiction Code" := TempSalesTaxAmtLine."Tax Jurisdiction Code";
    IF TempSalesTaxAmtLine."Tax Amount" <> 0 THEN BEGIN
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt +

    // Delete the following lines.
    CurrExchRate.ExchangeAmtLCYToFCY(
    Usedate,PurchHeader."Currency Code",TempSalesTaxAmtLine."Tax Amount",PurchHeader."Currency Factor");
    // End of the deleted lines.

    GenJnlLine."Source Curr. VAT Amount" :=
    SalesTaxCalculate.ArithmeticRound(RemSalesTaxSrcAmt,Currency."Amount Rounding Precision");
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt - GenJnlLine."Source Curr. VAT Amount";
    RemSalesTaxAmt := RemSalesTaxAmt + TempSalesTaxAmtLine."Tax Amount";
    ...

    Thay thế mã

    ...END;
    GenJnlLine."Tax Jurisdiction Code" := TempSalesTaxAmtLine."Tax Jurisdiction Code";
    IF TempSalesTaxAmtLine."Tax Amount" <> 0 THEN BEGIN
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt +

    // Add the following line.
    TempSalesTaxAmtLine."Tax Base Amount FCY" * TempSalesTaxAmtLine."Tax %" / 100;
    // End of the added line.

    GenJnlLine."Source Curr. VAT Amount" :=
    SalesTaxCalculate.ArithmeticRound(RemSalesTaxSrcAmt,Currency."Amount Rounding Precision");
    RemSalesTaxSrcAmt := RemSalesTaxSrcAmt - GenJnlLine."Source Curr. VAT Amount";
    RemSalesTaxAmt := RemSalesTaxAmt + TempSalesTaxAmtLine."Tax Amount";
    ...
  4. Thay đổi mã trong hàm PostProvincialSalesTaxToGL Purch.-bài Codeunit (90) như sau:
    Mã hiện tại

    ...TaxJurisdiction.TESTFIELD("Tax Account (Purchases)");
    GenJnlLine."Account No." := TaxJurisdiction."Tax Account (Purchases)";
    END;
    GenJnlLine.Amount := GenJnlLine."VAT Amount";

    // Delete the following lines.
    GenJnlLine."Source Curr. VAT Base Amount" := 0;
    GenJnlLine."VAT Base Amount (LCY)" := 0;
    GenJnlLine."VAT Base Amount" := 0;
    GenJnlLine."Source Curr. VAT Amount" := 0;
    // End of the deleted lines.

    GenJnlLine."VAT Amount (LCY)" := 0;
    GenJnlLine."VAT Amount" := 0;
    GenJnlLine.Quantity := 0;
    GenJnlLine."VAT Difference" := 0;
    ...

    Thay thế mã

    ...TaxJurisdiction.TESTFIELD("Tax Account (Purchases)");
    GenJnlLine."Account No." := TaxJurisdiction."Tax Account (Purchases)";
    END;
    GenJnlLine.Amount := GenJnlLine."VAT Amount";

    // Add the following lines.
    GenJnlLine."Source Currency Amount" := GenJnlLine."Source Curr. VAT Amount";
    GenJnlLine."Source Curr. VAT Base Amount" := 0;
    GenJnlLine."VAT Base Amount (LCY)" := 0;
    GenJnlLine."VAT Base Amount" := 0;
    // End of the added lines.

    GenJnlLine."VAT Amount (LCY)" := 0;
    GenJnlLine."VAT Amount" := 0;
    GenJnlLine.Quantity := 0;
    GenJnlLine."VAT Difference" := 0;
    ...
  5. Thay đổi mã trong hàm AddSalesLine thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Delete the following line.
    "Tax Base Amount" := (SalesLine."Line Amount" - SalesLine."Inv. Discount Amount") / ExchangeFactor;
    // End of the deleted line.

    "Line Amount" := SalesLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := SalesLine."Tax Liable";
    Quantity := SalesLine."Quantity (Base)";
    "Invoice Discount Amount" := SalesLine."Inv. Discount Amount";
    ...

    Thay thế mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesLine."Line Amount" - SalesLine."Inv. Discount Amount",ExchangeFactor,FALSE);
    // End of the added line.

    "Line Amount" := SalesLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := SalesLine."Tax Liable";
    Quantity := SalesLine."Quantity (Base)";
    "Invoice Discount Amount" := SalesLine."Inv. Discount Amount";
    ...

    Hiện có mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesLine."Line Amount" / ExchangeFactor);
    IF SalesLine."Tax Liable" THEN
    "Tax Liable" := SalesLine."Tax Liable";

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + ((SalesLine."Line Amount" - SalesLine."Inv. Discount Amount") / ExchangeFactor);
    // End of the deleted line.

    "Tax Amount" := 0;
    Quantity := Quantity + SalesLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + SalesLine."Inv. Discount Amount";
    MODIFY;
    ...

    Thay thế mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesLine."Line Amount" / ExchangeFactor);
    IF SalesLine."Tax Liable" THEN
    "Tax Liable" := SalesLine."Tax Liable";

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesLine."Line Amount" - SalesLine."Inv. Discount Amount",ExchangeFactor,TRUE);
    // End of the added line.

    "Tax Amount" := 0;
    Quantity := Quantity + SalesLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + SalesLine."Inv. Discount Amount";
    MODIFY;
    ...
  6. Thay đổi mã trong hàm AddSalesInvoiceLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := SalesInvoiceLine."Line Amount" / ExchangeFactor;

    // Delete the following line.
    "Tax Base Amount" := SalesInvoiceLine."VAT Base Amount" / ExchangeFactor;
    // End of the deleted line.

    Quantity := SalesInvoiceLine.Quantity;
    "Tax Liable" := SalesInvoiceLine."Tax Liable";
    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := SalesInvoiceLine."Line Amount" / ExchangeFactor;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesInvoiceLine."VAT Base Amount",ExchangeFactor,FALSE);
    // End of the added line.

    Quantity := SalesInvoiceLine.Quantity;
    "Tax Liable" := SalesInvoiceLine."Tax Liable";
    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesInvoiceLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (SalesInvoiceLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + SalesInvoiceLine.Quantity;
    IF SalesInvoiceLine."Tax Liable" THEN
    "Tax Liable" := SalesInvoiceLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesInvoiceLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesInvoiceLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + SalesInvoiceLine.Quantity;
    IF SalesInvoiceLine."Tax Liable" THEN
    "Tax Liable" := SalesInvoiceLine."Tax Liable";
    InsertRec := FALSE;
    ...
  7. Thay đổi mã trong hàm AddSalesCrMemoLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := SalesCrMemoLine."Line Amount" / ExchangeFactor;

    // Delete the following line.
    "Tax Base Amount" := SalesCrMemoLine."VAT Base Amount" / ExchangeFactor;
    // End of the deleted line.

    Quantity := SalesCrMemoLine.Quantity;
    "Tax Liable" := SalesCrMemoLine."Tax Liable";
    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := SalesCrMemoLine."Line Amount" / ExchangeFactor;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesCrMemoLine."VAT Base Amount",ExchangeFactor,FALSE);
    // End of the added line.

    Quantity := SalesCrMemoLine.Quantity;
    "Tax Liable" := SalesCrMemoLine."Tax Liable";
    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesCrMemoLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (SalesCrMemoLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + SalesCrMemoLine.Quantity;
    IF SalesCrMemoLine."Tax Liable" THEN
    "Tax Liable" := SalesCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (SalesCrMemoLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,SalesCrMemoLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + SalesCrMemoLine.Quantity;
    IF SalesCrMemoLine."Tax Liable" THEN
    "Tax Liable" := SalesCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...
  8. Thay đổi mã trong hàm AddPurchLine thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Delete the following line.
    "Tax Base Amount" := (PurchLine."Line Amount" - PurchLine."Inv. Discount Amount") / ExchangeFactor;
    // End of the deleted line.

    "Line Amount" := PurchLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := PurchLine."Tax Liable";
    "Use Tax" := PurchLine."Use Tax";
    ...

    Thay thế mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchLine."Line Amount" - PurchLine."Inv. Discount Amount",ExchangeFactor,FALSE);
    // End of the added line.

    "Line Amount" := PurchLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := PurchLine."Tax Liable";
    "Use Tax" := PurchLine."Use Tax";
    ...

    Hiện có mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchLine."Line Amount" / ExchangeFactor);
    IF PurchLine."Tax Liable" THEN
    "Tax Liable" := PurchLine."Tax Liable";

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + ((PurchLine."Line Amount" - PurchLine."Inv. Discount Amount") / ExchangeFactor);
    // End of the deleted line.

    "Tax Amount" := 0;
    Quantity := Quantity + PurchLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + PurchLine."Inv. Discount Amount";
    MODIFY;
    ...

    Thay thế mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchLine."Line Amount" / ExchangeFactor);
    IF PurchLine."Tax Liable" THEN
    "Tax Liable" := PurchLine."Tax Liable";

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchLine."Line Amount" - PurchLine."Inv. Discount Amount",ExchangeFactor,TRUE);
    // End of the added line.

    "Tax Amount" := 0;
    Quantity := Quantity + PurchLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + PurchLine."Inv. Discount Amount";
    MODIFY;
    ...
  9. Thay đổi mã trong hàm AddPurchInvoiceLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := PurchInvLine."Line Amount" / ExchangeFactor;

    // Delete the following line.
    "Tax Base Amount" := PurchInvLine."VAT Base Amount" / ExchangeFactor;
    // End of the deleted line.

    Quantity := PurchInvLine.Quantity;
    "Tax Liable" := PurchInvLine."Tax Liable";
    "Use Tax" := PurchInvLine."Use Tax";
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := PurchInvLine."Line Amount" / ExchangeFactor;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchInvLine."VAT Base Amount",ExchangeFactor,FALSE);
    // End of the added line.

    Quantity := PurchInvLine.Quantity;
    "Tax Liable" := PurchInvLine."Tax Liable";
    "Use Tax" := PurchInvLine."Use Tax";
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchInvLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (PurchInvLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + PurchInvLine.Quantity;
    IF PurchInvLine."Tax Liable" THEN
    "Tax Liable" := PurchInvLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchInvLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchInvLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + PurchInvLine.Quantity;
    IF PurchInvLine."Tax Liable" THEN
    "Tax Liable" := PurchInvLine."Tax Liable";
    InsertRec := FALSE;
    ...
  10. Thay đổi mã trong hàm AddPurchCrMemoLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := PurchCrMemoLine."Line Amount" / ExchangeFactor;

    // Delete the following line.
    "Tax Base Amount" := PurchCrMemoLine."VAT Base Amount" / ExchangeFactor;
    // End of the deleted line.

    Quantity := PurchCrMemoLine.Quantity;
    "Tax Liable" := PurchCrMemoLine."Tax Liable";
    "Use Tax" := PurchCrMemoLine."Use Tax";
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := PurchCrMemoLine."Line Amount" / ExchangeFactor;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchCrMemoLine."VAT Base Amount",ExchangeFactor,FALSE);
    // End of the added line.

    Quantity := PurchCrMemoLine.Quantity;
    "Tax Liable" := PurchCrMemoLine."Tax Liable";
    "Use Tax" := PurchCrMemoLine."Use Tax";
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchCrMemoLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (PurchCrMemoLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + PurchCrMemoLine.Quantity;
    IF PurchCrMemoLine."Tax Liable" THEN
    "Tax Liable" := PurchCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (PurchCrMemoLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,PurchCrMemoLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + PurchCrMemoLine.Quantity;
    IF PurchCrMemoLine."Tax Liable" THEN
    "Tax Liable" := PurchCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...
  11. Thay đổi mã trong hàm AddServiceLine thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Delete the following line.
    "Tax Base Amount" := (ServiceLine."Line Amount" - ServiceLine."Inv. Discount Amount") / ExchangeFactor;
    // End of the deleted line.

    "Line Amount" := ServiceLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := ServiceLine."Tax Liable";
    Quantity := ServiceLine."Quantity (Base)";
    "Invoice Discount Amount" := ServiceLine."Inv. Discount Amount";
    ...

    Thay thế mã 1

    ..."Round Tax" := TaxArea."Round Tax";
    TaxJurisdiction.GET("Tax Jurisdiction Code");
    "Is Report-to Jurisdiction" := ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,ServiceLine."Line Amount" - ServiceLine."Inv. Discount Amount",ExchangeFactor,FALSE);
    // End of the added line.

    "Line Amount" := ServiceLine."Line Amount" / ExchangeFactor;
    "Tax Liable" := ServiceLine."Tax Liable";
    Quantity := ServiceLine."Quantity (Base)";
    "Invoice Discount Amount" := ServiceLine."Inv. Discount Amount";
    ...

    Hiện có mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServiceLine."Line Amount" / ExchangeFactor);
    IF ServiceLine."Tax Liable" THEN
    "Tax Liable" := ServiceLine."Tax Liable";

    // Delete the following line.
    "Tax Base Amount" :=
    "Tax Base Amount" + ((ServiceLine."Line Amount" - ServiceLine."Inv. Discount Amount") / ExchangeFactor);
    // End of the deleted line.

    "Tax Amount" := 0;
    Quantity := Quantity + ServiceLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + ServiceLine."Inv. Discount Amount";
    MODIFY;
    ...

    Thay thế mã 2

    ...END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServiceLine."Line Amount" / ExchangeFactor);
    IF ServiceLine."Tax Liable" THEN
    "Tax Liable" := ServiceLine."Tax Liable";

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,ServiceLine."Line Amount" - ServiceLine."Inv. Discount Amount",ExchangeFactor,TRUE);
    // End of the added line.

    "Tax Amount" := 0;
    Quantity := Quantity + ServiceLine."Quantity (Base)";
    "Invoice Discount Amount" := "Invoice Discount Amount" + ServiceLine."Inv. Discount Amount";
    MODIFY;
    ...
  12. Thay đổi mã trong hàm AddServInvoiceLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := ServInvLine."Line Amount" / ExchangeFactor;

    // Delete the following lines.
    "Tax Base Amount" := ServInvLine."VAT Base Amount" / ExchangeFactor;
    Quantity := ServInvLine.Quantity;
    "Tax Liable" := ServInvLine."Tax Liable";

    // End of the deleted line.

    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    INSERT;
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := ServInvLine."Line Amount" / ExchangeFactor;

    // Add the following lines.
    SetTaxBaseAmount(TempSalesTaxLine,ServInvLine."VAT Base Amount",ExchangeFactor,FALSE);
    Quantity := ServInvLine.Quantity;
    "Tax Liable" := ServInvLine."Tax Liable";
    // End of the added lines.

    "Calculation Order" := TaxAreaLine."Calculation Order";
    InsertRec := TRUE;
    INSERT;
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServInvLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (ServInvLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + ServInvLine.Quantity;
    IF ServInvLine."Tax Liable" THEN
    "Tax Liable" := ServInvLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServInvLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,ServInvLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + ServInvLine.Quantity;
    IF ServInvLine."Tax Liable" THEN
    "Tax Liable" := ServInvLine."Tax Liable";
    InsertRec := FALSE;
    ...
  13. Thay đổi mã trong hàm AddServCrMemoLines thuế bán hàng tính Codeunit (398) như sau:
    Hiện có mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := ServCrMemoLine."Line Amount" / ExchangeFactor;

    // Delete the following line.
    "Tax Base Amount" := ServCrMemoLine."VAT Base Amount" / ExchangeFactor;
    // End of the deleted line.

    Quantity := ServCrMemoLine.Quantity;
    "Tax Liable" := ServCrMemoLine."Tax Liable";

    "Calculation Order" := TaxAreaLine."Calculation Order";
    ...

    Thay thế mã 1

    ..."Is Report-to Jurisdiction" :=
    ("Tax Jurisdiction Code" = TaxJurisdiction."Report-to Jurisdiction");
    END;
    "Line Amount" := ServCrMemoLine."Line Amount" / ExchangeFactor;

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,ServCrMemoLine."VAT Base Amount",ExchangeFactor,FALSE);
    // End of the added line.

    Quantity := ServCrMemoLine.Quantity;
    "Tax Liable" := ServCrMemoLine."Tax Liable";

    "Calculation Order" := TaxAreaLine."Calculation Order";
    ...

    Hiện có mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServCrMemoLine."Line Amount" / ExchangeFactor);

    // Delete the following line.
    "Tax Base Amount" := "Tax Base Amount" + (ServCrMemoLine."VAT Base Amount" / ExchangeFactor);
    // End of the deleted line.

    Quantity := Quantity + ServCrMemoLine.Quantity;
    IF ServCrMemoLine."Tax Liable" THEN
    "Tax Liable" := ServCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...

    Thay thế mã 2

    ...InsertRec := TRUE;
    INSERT;
    END ELSE BEGIN
    "Line Amount" := "Line Amount" + (ServCrMemoLine."Line Amount" / ExchangeFactor);

    // Add the following line.
    SetTaxBaseAmount(TempSalesTaxLine,ServCrMemoLine."VAT Base Amount",ExchangeFactor,TRUE);
    // End of the added line.

    Quantity := Quantity + ServCrMemoLine.Quantity;
    IF ServCrMemoLine."Tax Liable" THEN
    "Tax Liable" := ServCrMemoLine."Tax Liable";
    InsertRec := FALSE;
    ...
  14. Thêm chức năng SetTaxBaseAmount trong thuế bán hàng tính Codeunit (398) như sau:

    LOCAL PROCEDURE SetTaxBaseAmount@1020031(VAR SalesTaxAmountLine@1020001 : Record 10011;Value@1020000 : Decimal;ExchangeFactor@1020002 : Decimal;Increment@1020003 : Boolean);      BEGIN
    WITH SalesTaxAmountLine DO BEGIN
    IF Increment THEN
    "Tax Base Amount FCY" += Value
    ELSE
    "Tax Base Amount FCY" := Value;
    "Tax Base Amount" := "Tax Base Amount FCY" / ExchangeFactor;
    END;
    END;



Điều kiện tiên quyết

Bạn phải có một trong các sản phẩm được cài đặt để áp dụng hotfix này:

  • Phiên bản Microsoft Dynamics NAV 2009 R2 Bắc Mỹ

  • Phiên bản Bắc Mỹ của Microsoft Dynamics NAV 2009 Service Pack 1

Thông tin về việc loại bỏ

Bạn không thể xoá hotfix này.

Trạng thái

Microsoft đã xác nhận rằng đây là sự cố trong sản phẩm của Microsoft được liệt kê trong phần "Áp dụng cho".

Lưu ý Đây là một bài viết "XUẤT BẢN NHANH" được tạo trực tiếp từ trung tâm hỗ trợ của Microsoft. Thông tin này được cung cấp-trả lời cho các vấn đề mới xuất hiện. Vì nhanh chóng có sẵn, các tài liệu có thể bao gồm lỗi và có thể được sửa đổi bất kỳ lúc nào mà không cần thông báo. Xem Điều khoản sử dụng để xem xét khác.

Bạn cần thêm trợ giúp?

Bạn muốn xem các tùy chọn khác?

Khám phá các lợi ích của gói đăng ký, xem qua các khóa đào tạo, tìm hiểu cách bảo mật thiết bị của bạn và hơn thế nữa.

Cộng đồng giúp bạn đặt và trả lời các câu hỏi, cung cấp phản hồi và lắng nghe ý kiến từ các chuyên gia có kiến thức phong phú.

Thông tin này có hữu ích không?

Bạn hài lòng đến đâu với chất lượng dịch thuật?
Điều gì ảnh hưởng đến trải nghiệm của bạn?
Khi nhấn gửi, phản hồi của bạn sẽ được sử dụng để cải thiện các sản phẩm và dịch vụ của Microsoft. Người quản trị CNTT của bạn sẽ có thể thu thập dữ liệu này. Điều khoản về quyền riêng tư.

Cảm ơn phản hồi của bạn!

×