שורת תזכיר האשראי אינו כלול ביומן סטטיסטיקה בעת פרסום תזכיר אשראי פריט חיוב עבור ספק האיחוד האירופי בתקופה שונה של החשבונית המפנה ב- Microsoft Dynamics NAV 2009

חל על
Microsoft Dynamics NAV 2009 R2 Dynamics NAV 2009 Service Pack 1

מאמר זה חל על Microsoft Dynamics NAV 2009 עבור כל המדינות ואזורי השפות.

סימפטומים

בעת פרסום תזכיר אשראי פריט חיוב עבור ספק האיחוד האירופי (EU) בתקופה אחרת של החשבונית המפנה ב- Microsoft Dynamics NAV 2009 R2 וב- Microsoft Dynamics NAV 2009 Service Pack 1 (SP1), שורת תזכיר האשראי אינה כלולה ביומן Intrastat.

פתרון

מידע אודות תיקונים חמים

תיקון חם נתמך זמין כעת מ- Microsoft. עם זאת, הוא מיועד רק לתיקון הבעיה המתוארת במאמר זה. החל אותו רק על מערכות שנתקלות בבעיה ספציפית זו. תיקון חם זה עשוי לקבל בדיקות נוספות. לכן, אם אתה לא מושפע באופן חמור מבעיה זו, מומלץ להמתין ל- Service Pack הבא של Microsoft Dynamics NAV 2009 או לגירסת MICROSOFT Dynamics NAV הבאה המכילה תיקון חם זה.

הערה במקרים מיוחדים, חיובים שנצבורים בדרך כלל עבור שיחות תמיכה עשויים להבוטל אם מומחה תמיכה טכנית עבור Microsoft Dynamics ומוצרים קשורים קובע שעדכון ספציפי יפתור את הבעיה. עלויות התמיכה הרגילות יחולו על שאלות ובעיות תמיכה נוספות שלא עומדות בדרישות לעדכון הספציפי הרלוונטי.

            
          

מידע התקנה

Microsoft מספקת דוגמאות תיכנות לאיור בלבד, ללא אחריות, מפורשת או משתמעת. הדבר כולל, אך אינו מוגבל לאחריות המשתמעת של סוחר או התאמה למטרה מסוימת. מאמר זה מבוסס על ההנחה שאתה מכיר את שפת התיכנות המודגמת, עם הכלים המשמשים ליצירת הליכים ולאתר באגים. מהנדסי התמיכה של Microsoft יכולים לעזור להסביר את הפונקציונליות של הליך מסוים, אך הם לא ישנו דוגמאות אלה כדי לספק פונקציונליות נוספת או לבנות הליכים שיסייעו לך לעמוד בדרישות הספציפיות שלך.

הערה לפני התקנת תיקון חם זה, ודא כי כל משתמשי לקוח Microsoft Navision נרשם המערכת. הדבר כולל משתמשי לקוח של Microsoft Navision Application Services (NAS). עליך להיות משתמש הלקוח היחיד שנכנס בעת יישום תיקון חם זה.

כדי ליישם תיקון חם זה, דרוש לך רשיון מפתח.

אנו ממליצים להקצות לחשבון המשתמש בחלון כניסות Windows או בחלון כניסות מסד נתונים את מזהה התפקיד "SUPER". אם אין אפשרות להקצות לחשבון המשתמש את מזהה התפקיד "SUPER", עליך לוודא שלחשבון המשתמש יש את ההרשאות הבאות:

  • ההרשאה Modify עבור האובייקט שאתה תשנה.
  • ההרשאה Execute עבור אובייקט System Object ID 5210 ולאובייקט System Object ID 9015.

                
הערה אין צורך להחזיק בזכויות על מאגרי הנתונים אלא אם עליך לבצע תיקון נתונים.

שינויי קוד

הערה בדוק תמיד את תיקוני הקוד בסביבה מבוקרת לפני החלת התיקונים על מחשבי הייצור שלך.
כדי לפתור בעיה זו, שנה את הקוד בדוח Get Item Ledger Entries (594). לשם כך, בצע את השלבים הבאים:

  1. שנה את הקוד של מספר פריט הנתונים 2 באופן הבא:
    קוד קיים 1

    ...
    SETRANGE("Country/Region Code",'');
    END;
    
    IntrastatJnlLine2.SETCURRENTKEY("Source Type","Source Entry No.");
    IntrastatJnlLine2.SETRANGE("Source Type",IntrastatJnlLine2."Source Type"::"Item entry");
    ...
    
    

    קוד חלופי 1

    ...
    SETRANGE("Country/Region Code",'');
    END;
    
    // Add the following line.
    IntrastatJnlLine2.SETRANGE("Journal Batch Name",IntrastatJnlBatch.Name);
    // End of the line.
    
    IntrastatJnlLine2.SETCURRENTKEY("Source Type","Source Entry No.");
    IntrastatJnlLine2.SETRANGE("Source Type",IntrastatJnlLine2."Source Type"::"Item entry");
    ...
    
    

    קוד קיים 2

    ...
    WITH ValueEntry DO BEGIN
    SETCURRENTKEY("Item Ledger Entry No.");
    
    // Delete the following line.
    SETRANGE("Valuation Date",StartDate,EndDate);
    // End of the line.
    
    SETRANGE("Entry Type","Entry Type"::"Direct Cost");
    SETFILTER(
    "Item Ledger Entry Type",'%1|%2|%3',
    ...
    
    

    קוד חלופי 2

    ...
    WITH ValueEntry DO BEGIN
    SETCURRENTKEY("Item Ledger Entry No.");
    
    // Add the following line.
    SETRANGE("Posting Date",StartDate,EndDate);
    // End of the line.
    
    SETRANGE("Entry Type","Entry Type"::"Direct Cost");
    SETFILTER(
    "Item Ledger Entry Type",'%1|%2|%3',
    ...
    
    

    קוד קיים 3

    ...
    END;
    END;
    
    // Delete the following lines.
    OnAfterGetRecord=VAR
    Location@1000 : Record 14;
    ItemLedgEntry@1001 : Record 32;
    Include@1002 : Boolean;
    BEGIN
    // End of the lines.
    
    IntrastatJnlLine2.SETRANGE("Source Entry No.","Entry No.");
    IF IntrastatJnlLine2.FINDFIRST THEN
    CurrReport.SKIP;
    ...
    
    

    קוד חלופי 3

    ...
    END;
    END;
    
    OnAfterGetRecord=BEGIN
    IntrastatJnlLine2.SETRANGE("Source Entry No.","Entry No.");
    IF IntrastatJnlLine2.FINDFIRST THEN
    CurrReport.SKIP;
    ...
    
    

    קוד קיים 4

    ...
    IF IntrastatJnlLine2.FINDFIRST THEN
    CurrReport.SKIP;
    
    // Delete the following lines.
    IF "Entry Type" IN ["Entry Type"::Sale,"Entry Type"::Purchase] THEN BEGIN
    ItemLedgEntry.RESET;
    ItemLedgEntry.SETCURRENTKEY("Document No.","Document Type");
    ItemLedgEntry.SETRANGE("Document No.","Document No.");
    ItemLedgEntry.SETRANGE("Item No.","Item No.");
    ItemLedgEntry.SETRANGE(Correction,TRUE);
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Sales Shipment");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Sales Return Receipt");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Purchase Receipt");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Purchase Return Shipment");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    END;
    
    CASE TRUE OF
    "Drop Shipment":
    BEGIN
    IF ("Country/Region Code" = CompanyInfo."Country/Region Code") OR
    ("Country/Region Code" = '')
    THEN
    CurrReport.SKIP;
    IF "Applies-to Entry" = 0 THEN BEGIN
    ItemLedgEntry.SETCURRENTKEY("Item No.","Posting Date");
    ItemLedgEntry.SETRANGE("Item No.","Item No.");
    ItemLedgEntry.SETRANGE("Posting Date","Posting Date");
    ItemLedgEntry.SETRANGE("Applies-to Entry","Entry No.");
    ItemLedgEntry.FINDFIRST;
    END ELSE
    ItemLedgEntry.GET("Applies-to Entry");
    IF (ItemLedgEntry."Country/Region Code" <> CompanyInfo."Country/Region Code") AND
    (ItemLedgEntry."Country/Region Code" <> '')
    THEN
    CurrReport.SKIP;
    END;
    "Entry Type" = "Entry Type"::Transfer:
    BEGIN
    IF ("Country/Region Code" = CompanyInfo."Country/Region Code") OR
    ("Country/Region Code" = '')
    THEN
    CurrReport.SKIP;
    IF "Transfer Order No." = '' THEN BEGIN
    Location.GET("Location Code");
    IF (Location."Country/Region Code" <> '') AND
    (Location."Country/Region Code" <> CompanyInfo."Country/Region Code")
    THEN
    CurrReport.SKIP;
    END ELSE BEGIN
    ItemLedgEntry.SETRANGE("Transfer Order No.","Transfer Order No.");
    ItemLedgEntry.SETFILTER("Country/Region Code",'%1 | %2','',CompanyInfo."Country/Region Code");
    IF ItemLedgEntry.FINDSET THEN
    REPEAT
    Location.GET(ItemLedgEntry."Location Code");
    IF Location."Use As In-Transit" THEN
    Include := TRUE;
    UNTIL Include OR (ItemLedgEntry.NEXT = 0);
    IF NOT Include THEN
    CurrReport.SKIP;
    END;
    END;
    "Location Code" <> '':
    BEGIN
    Location.GET("Location Code");
    CheckILE(Location."Country/Region Code");
    END
    ELSE BEGIN
    IF "Entry Type" = "Entry Type"::Purchase THEN
    CheckILE(CompanyInfo."Ship-to Country/Region Code");
    IF "Entry Type" = "Entry Type"::Sale THEN
    CheckILE(CompanyInfo."Country/Region Code");
    END;
    END;
    // End of the lines.
    
    TotalInvoicedQty := 0;
    TotalAmt := 0;
    TotalAmtExpected := 0;
    ...
    
    

    קוד חלופי 4

    ...
    IF IntrastatJnlLine2.FINDFIRST THEN
    CurrReport.SKIP;
    
    // Add the following line.
    TestILE("Item Ledger Entry");
    // End of the line.
    
    TotalInvoicedQty := 0;
    TotalAmt := 0;
    TotalAmtExpected := 0;
    ...
    
    
  2. שנה את הקוד של מספר פריט הנתונים 4 באופן הבא:
    קוד קיים

    ...
    {
    }
    }
    }
    REQUESTFORM
    {
    ...
    
    

    קוד חלופי

    ...
    {
    }
    }
    
    // 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");
    
    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
    {
    ...
    
    
  3. שנה את הקוד בפונקציה TestILE באופן הבא:
    קוד קיים

    ...
    END;
    END;
    
    BEGIN
    END.
    }
    ...
    
    

    קוד חלופי

    ...
    END;
    END;
    
    // Add the following lines.
    PROCEDURE TestILE@5(ILE@1000 : Record 32);
    VAR
    ItemLedgEntry@1003 : Record 32;
    Location@1002 : Record 14;
    Include@1001 : Boolean;
    BEGIN
    WITH ILE DO BEGIN
    IF "Entry Type" IN ["Entry Type"::Sale,"Entry Type"::Purchase] THEN BEGIN
    ItemLedgEntry.RESET;
    ItemLedgEntry.SETCURRENTKEY("Document No.","Document Type");
    ItemLedgEntry.SETRANGE("Document No.","Document No.");
    ItemLedgEntry.SETRANGE("Item No.","Item No.");
    ItemLedgEntry.SETRANGE(Correction,TRUE);
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Sales Shipment");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Sales Return Receipt");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Purchase Receipt");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    
    ItemLedgEntry.SETRANGE("Document Type","Document Type"::"Purchase Return Shipment");
    IF NOT ItemLedgEntry.ISEMPTY THEN
    CurrReport.SKIP;
    END;
    
    CASE TRUE OF
    "Drop Shipment":
    BEGIN
    IF ("Country/Region Code" = CompanyInfo."Country/Region Code") OR
    ("Country/Region Code" = '')
    THEN
    CurrReport.SKIP;
    IF "Applies-to Entry" = 0 THEN BEGIN
    ItemLedgEntry.SETCURRENTKEY("Item No.","Posting Date");
    ItemLedgEntry.SETRANGE("Item No.","Item No.");
    ItemLedgEntry.SETRANGE("Posting Date","Posting Date");
    ItemLedgEntry.SETRANGE("Applies-to Entry","Entry No.");
    ItemLedgEntry.FINDFIRST;
    END ELSE
    ItemLedgEntry.GET("Applies-to Entry");
    IF (ItemLedgEntry."Country/Region Code" <> CompanyInfo."Country/Region Code") AND
    (ItemLedgEntry."Country/Region Code" <> '')
    THEN
    CurrReport.SKIP;
    END;
    "Entry Type" = "Entry Type"::Transfer:
    BEGIN
    IF ("Country/Region Code" = CompanyInfo."Country/Region Code") OR
    ("Country/Region Code" = '')
    THEN
    CurrReport.SKIP;
    IF "Transfer Order No." = '' THEN BEGIN
    Location.GET("Location Code");
    IF (Location."Country/Region Code" <> '') AND
    (Location."Country/Region Code" <> CompanyInfo."Country/Region Code")
    THEN
    CurrReport.SKIP;
    END ELSE BEGIN
    ItemLedgEntry.SETRANGE("Transfer Order No.","Transfer Order No.");
    ItemLedgEntry.SETFILTER("Country/Region Code",'%1 | %2','',CompanyInfo."Country/Region Code");
    IF ItemLedgEntry.FINDSET THEN
    REPEAT
    Location.GET(ItemLedgEntry."Location Code");
    IF Location."Use As In-Transit" THEN
    Include := TRUE;
    UNTIL Include OR (ItemLedgEntry.NEXT = 0);
    IF NOT Include THEN
    CurrReport.SKIP;
    END;
    END;
    "Location Code" <> '':
    BEGIN
    Location.GET("Location Code");
    CheckILE(Location."Country/Region Code");
    END;
    ELSE BEGIN
    IF "Entry Type" = "Entry Type"::Purchase THEN
    CheckILE(CompanyInfo."Ship-to Country/Region Code");
    IF "Entry Type" = "Entry Type"::Sale THEN
    CheckILE(CompanyInfo."Country/Region Code");
    END;
    END;
    END;
    END;
    
    PROCEDURE InsertValueEntryLine@6();
    VAR
    Location@1000 : 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.
    }
    ...
    
    

דרישות מוקדמות

דרוש לך אחד המוצרים הבאים מותקנים כדי להחיל תיקון חם זה:

  • Microsoft Dynamics NAV 2009 R2
  • Microsoft Dynamics NAV 2009 Service Pack 1

מידע על הסרה

אין באפשרותך להסיר תיקון חם זה.

מצב

Microsoft אישרה שזוהי בעיה במוצרי Microsoft המפורטים בסעיף "חל על".

הערה זהו מאמר "FAST PUBLISH" שנוצר ישירות מתוך ארגון התמיכה של Microsoft. המידע הכלול ב- Herein מסופק כפי שהוא בתגובה לבעיות מתפתחות. כתוצאה מההפיכתה לזמינה, החומרים עשויים לכלול שגיאות טיפוגרפיות וייתכן שיתוקנו בכל עת ללא הודעה מוקדמת. ראה תנאי שימוש לקבלת שיקולים אחרים.