Raportul "Declarație de furnizor" afişează o incorecte total când o factură se aplică de o plată în cazul în care a fost dedusă reduceri de plată în versiunea portugheză a Microsoft Dynamics NAV 2009. Valoarea de reducere plată este afișat ca soldul total. Urmați pașii din secțiunea modificări de cod pentru a rezolva această problemă. Această problemă se produce în următorul produs:
-
Portugheză-versiunea de Microsoft Dynamics NAV 2009 R2
-
Versiunea portugheză Microsoft Dynamics NAV 2009 SP1
Rezolvare
Informații despre remedierea rapidă
Un hotfix acceptat este acum disponibil de la Microsoft. Cu toate acestea, acesta este destinat numai corectării problemei descrise în acest articol. Aplicați-o numai pe sistemele care întâmpină această problemă anume. Această remediere rapidă poate să necesite testare suplimentară. De aceea, dacă nu sunteți grav afectat de această problemă, vă recomandăm să așteptați următorul pachet service pack Microsoft Dynamics NAV 2009 sau versiunea Microsoft Dynamics NAV următoare, care conține această remediere rapidă.
Notă În cazuri speciale, costurile implicate de obicei pentru asistență apeluri pot fi anulate dacă un specialist în asistență tehnică pentru Microsoft Dynamics și produse asociate stabilește că o anumită actualizare va rezolva problema. Se vor aplica costurile uzuale de asistenţă pentru întrebări suplimentare de asistenţă şi pentru probleme ce nu fac obiectul actualizării în cauză.
Informaţii despre instalare
Microsoft furnizează exemple de programare scop ilustrativ, fără nicio garanţie explicită sau implicită. Aceasta include, dar nu se limitează la, garanţiile implicite de vandabilitate sau de potrivire pentru un anumit scop. Acest articol presupune că sunteţi familiarizat cu limbajul de programare care este prezentat şi cu instrumentele utilizate pentru a crea şi a depana proceduri. Specialiștii în asistență Microsoft pot ajuta la explicarea funcționalității unei anumite proceduri. Cu toate acestea, nu vor modifica aceste exemple pentru a furniza funcționalitate suplimentară construi proceduri pentru a răspunde cerințelor dvs. specifice.
Notă Înainte de a instala această remediere rapidă, verificați dacă toți utilizatorii de client Microsoft Dynamics NAV sunt log off sistemul. Aceasta include servicii Microsoft Dynamics NAV Application Server (NAS). Ar trebui să fie singurul client utilizatorului care este conectat când implementați această remediere rapidă.
Pentru a implementa această remediere rapidă, trebuie să aveți o licență de dezvoltare.
Vă recomandăm că contul de utilizator în fereastra Conectări Windows sau în fereastra Conectări bază de date se atribuie "SUPER" rolul ID-ul. În cazul în care contul de utilizator nu poate fi atribuit ID-ul "SUPER" rolul, trebuie să verificați că contul de utilizator are următoarele permisiuni:
-
Modify permisiunea pentru obiectul care se va schimba.
-
Permisiunea de executare pentru obiectul sistem obiect ID 5210 și sistem obiect ID 9015
obiect.
Notă Nu trebuie să aveți drepturi de la magazine de date decât dacă trebuie să efectuați o reparare de date.
Modificări de cod
Notă întotdeauna test cod remedieri într-un mediu controlat înainte de a aplica remedieri pentru computerele de producție. Înainte de a aplica modificarea, vă rugăm să importați toate actualizările SEPA.
Pentru a rezolva această problemă, urmați acești pași:
-
Modificați codul din elementul date numărul 1 din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent 1... Currency2.INSERT;
UNTIL Currency.NEXT = 0;
END;
// Delete the following line.
OnAfterGetRecord=BEGIN
// End of the deleted line.
CurrReport.LANGUAGE := Language.GetLanguageID("Language Code");
PrintLine := FALSE;
Vend2 := Vendor;
COPYFILTER("Currency Filter",Currency2.Code);
...Înlocuirea cod 1
... Currency2.INSERT;
UNTIL Currency.NEXT = 0;
END;
// Add the following lines.
OnAfterGetRecord=VAR
VendLedgEntry@1000 : Record 25;
BEGIN
// End of the added lines.
CurrReport.LANGUAGE := Language.GetLanguageID("Language Code");
PrintLine := FALSE;
Vend2 := Vendor;
COPYFILTER("Currency Filter",Currency2.Code);
...Cod existent 2
...PrintLine := Vend2."Net Change" <> 0;
UNTIL (Currency2.NEXT = 0) OR PrintLine;
END;
IF (NOT PrintLine) AND PrintAllHavingEntry THEN BEGIN
// Delete the following lines.
"Vendor Ledger Entry".RESET;
"Vendor Ledger Entry".SETCURRENTKEY("Vendor No.","Posting Date");
"Vendor Ledger Entry".SETRANGE("Vendor No.",Vendor."No.");
"Vendor Ledger Entry".SETRANGE("Posting Date",StartDate,EndDate);
Vendor.COPYFILTER("Currency Filter","Vendor Ledger Entry"."Currency Code");
PrintLine := "Vendor Ledger Entry".FIND('-');
// End of the deleted lines.
END;
IF NOT PrintLine THEN
CurrReport.SKIP;
...Înlocuirea cod 2
... PrintLine := Vend2."Net Change" <> 0;
UNTIL (Currency2.NEXT = 0) OR PrintLine;
END;
IF (NOT PrintLine) AND PrintAllHavingEntry THEN BEGIN
// Add the following lines.
VendLedgEntry.SETCURRENTKEY("Vendor No.","Posting Date");
VendLedgEntry.SETRANGE("Vendor No.",Vendor."No.");
VendLedgEntry.SETRANGE("Posting Date",StartDate,EndDate);
Vendor.COPYFILTER("Currency Filter",VendLedgEntry."Currency Code");
PrintLine := NOT VendLedgEntry.ISEMPTY;
// End of the added lines.
END;
IF NOT PrintLine THEN
CurrReport.SKIP;
... -
Modificați codul din elementul date numărul 4 din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent 1... }
{ PROPERTIES
{
DataItemIndent=3;
// Delete the following lines.
DataItemTable=Table25;
DataItemTableView=SORTING(Vendor No.,Posting Date);
OnPreDataItem=BEGIN
SETRANGE("Posting Date",StartDate,EndDate);
SETRANGE("Currency Code",Currency2.Code);
CurrReport.CREATETOTALS("Remaining Amount");
// End of the deleted lines.
IF Currency2.Code = '' THEN BEGIN
GLSetup.TESTFIELD("LCY Code");
CurrencyCode3 := GLSetup."LCY Code"
END ELSE
...Înlocuirea cod 1
... }
{ PROPERTIES
{
DataItemIndent=3;
// Add the following lines.
DataItemTable=Table2000000026;
DataItemTableView=SORTING(Number)
WHERE(Number=CONST(1));
DataItemVarName=VendLedEntryHdr;
PrintOnlyIfDetail=Yes;
}
SECTIONS
{
}
}
{ PROPERTIES
{
DataItemIndent=4;
DataItemTable=Table380;
DataItemTableView=SORTING(Vendor No.,Posting Date,Entry Type,Currency Code)
WHERE(Excluded from calculation=CONST(No),
Entry Type=FILTER(<>Application&<>Redrawal));
DataItemVarName=DtldVendLedgEntry;
PrintOnlyIfDetail=No;
OnPreDataItem=BEGIN
SETRANGE("Vendor No.",Vendor."No.");
SETRANGE("Posting Date",StartDate,EndDate);
SETRANGE("Currency Code",Currency2.Code);
// End of the added lines.
IF Currency2.Code = '' THEN BEGIN
GLSetup.TESTFIELD("LCY Code");
CurrencyCode3 := GLSetup."LCY Code"
END ELSE
...Cod existent 2
...END ELSE
CurrencyCode3 := Currency2.Code
END;
// Delete the following lines.
OnAfterGetRecord=BEGIN
// PT0002.begin
// VendBalance := VendBalance + "Remaining Amount";
VendBalance := VendBalance + "Original Amount";
// PT0002.end
// End of the deleted lines.
END;
DataItemLinkReference=Vendor;
DataItemLink=Vendor No.=FIELD(No.);
...Înlocuirea cod 2
... END ELSE
CurrencyCode3 := Currency2.Code
END;
// Add the following lines.
OnAfterGetRecord=VAR
VendLedgEntry@1000 : Record 25;
DtldVendLedgEntry1@1001 : Record 380;
BEGIN
RemainingAmount := 0;
PrintLine := TRUE;
CASE "Entry Type" OF
"Entry Type"::"Initial Entry":
BEGIN
VendLedgEntry.GET("Vendor Ledger Entry No.");
Description := VendLedgEntry.Description;
DueDate := VendLedgEntry."Due Date";
VendLedgEntry.SETRANGE("Date Filter",0D, EndDate);
VendLedgEntry.CALCFIELDS("Remaining Amount");
RemainingAmount := VendLedgEntry."Remaining Amount";
END;
"Entry Type"::"Payment Discount",
"Entry Type"::"Payment Discount (VAT Excl.)",
"Entry Type"::"Payment Discount (VAT Adjustment)",
"Entry Type"::"Payment Discount Tolerance",
"Entry Type"::"Payment Discount Tolerance (VAT Excl.)",
"Entry Type"::"Payment Discount Tolerance (VAT Adjustment)":
BEGIN
Description := Text006;
DueDate := 0D;
END;
"Entry Type"::"Payment Tolerance",
"Entry Type"::"Payment Tolerance (VAT Excl.)",
"Entry Type"::"Payment Tolerance (VAT Adjustment)":
BEGIN
Description := Text014;
DueDate := 0D;
END;
"Entry Type"::"Appln. Rounding",
"Entry Type"::"Correction of Remaining Amount":
BEGIN
Description := Text007;
DueDate := 0D;
END;
END;
IF PrintLine THEN
VendBalance := VendBalance + Amount;
// End of the added lines.
END;
DataItemLinkReference=Vendor;
DataItemLink=Vendor No.=FIELD(No.);
... -
Modificați codul din date element număr 4 secțiuni din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent 1... DataSetFieldName=Vendor_Ledger_Entry_Description }
{ 47 ;TextBox ;7980 ;0 ;1680 ;423 ;HorzAlign=Left;
FontSize=9;
CaptionML=ENU=Due Date;
// Delete the following lines.
SourceExpr=FORMAT("Due Date",0,4);
DataSetFieldName=Vendor_Ledger_Entry__Due_Date_ }
{ 48 ;TextBox ;13230;0 ;2310 ;423 ;FontSize=9;
CaptionML=ENU=Remaining Amount;
SourceExpr="Remaining Amount";
// End of the deleted lines.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=Vendor_Ledger_Entry__Remaining_Amount_ }
{ 49 ;TextBox ;15750;0 ;2310 ;423 ;FontSize=9;
...Înlocuirea cod 1
... DataSetFieldName=Vendor_Ledger_Entry_Description }
{ 47 ;TextBox ;7980 ;0 ;1680 ;423 ;HorzAlign=Left;
FontSize=9;
CaptionML=ENU=Due Date;
// Add the following lines.
SourceExpr=FORMAT(DueDate,0,4);
DataSetFieldName=Vendor_Ledger_Entry__Due_Date_ }
{ 48 ;TextBox ;13230;0 ;2310 ;423 ;FontSize=9;
CaptionML=ENU=Remaining Amount;
SourceExpr=RemainingAmount;
// End of the added lines.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=Vendor_Ledger_Entry__Remaining_Amount_ }
{ 49 ;TextBox ;15750;0 ;2310 ;423 ;FontSize=9;
...Cod existent 2
...AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=VendBalance_Control49 }
{ 54 ;TextBox ;10710;0 ;2310 ;423 ;FontSize=9;
// Delete the following line.
SourceExpr="Original Amount";
// End of the deleted line.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=Vendor_Ledger_Entry__Original_Amount_ }
{ 78 ;TextBox ;9870 ;0 ;840 ;423 ;FontSize=9;
...Înlocuirea cod 2
... AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=VendBalance_Control49 }
{ 54 ;TextBox ;10710;0 ;2310 ;423 ;FontSize=9;
// Add the following line.
SourceExpr=Amount;
// End of the added line.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=Vendor_Ledger_Entry__Original_Amount_ }
{ 78 ;TextBox ;9870 ;0 ;840 ;423 ;FontSize=9;
... -
Modificați codul din elementul date numărul 5 din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent...END;
OnAfterGetRecord=BEGIN
IF ISSERVICETIER THEN
// Delete the following lines.
VendBalance2 := VendBalance2 + "Remaining Amount"
ELSE
VendBalance := VendBalance + "Remaining Amount";
// End of the deleted lines.
END;
DataItemLinkReference=Vendor;
DataItemLink=Vendor No.=FIELD(No.);
...Cod de înlocuire
... END;
OnAfterGetRecord=BEGIN
IF ISSERVICETIER THEN
// Add the following lines.
VendBalance2 := VendBalance2 + RemainingAmount
ELSE
VendBalance := VendBalance + RemainingAmount;
// End of the added lines.
END;
DataItemLinkReference=Vendor;
DataItemLink=Vendor No.=FIELD(No.);
... -
Modificați codul din secțiunile 5 număr element date din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent...SourceExpr=Description;
DataSetFieldName=VendorLedgEntry2_Description }
{ 60 ;TextBox ;7980 ;0 ;1680 ;423 ;HorzAlign=Left;
FontSize=9;
// Delete the following lines.
SourceExpr=FORMAT("Due Date",0,4);
DataSetFieldName=VendorLedgEntry2__Due_Date_ }
{ 61 ;TextBox ;13230;0 ;2310 ;423 ;FontSize=9;
SourceExpr="Remaining Amount";
// End of the deleted lines.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=VendorLedgEntry2__Remaining_Amount_ }
{ 62 ;TextBox ;15750;0 ;2310 ;423 ;FontSize=9;
...Cod de înlocuire
... SourceExpr=Description;
DataSetFieldName=VendorLedgEntry2_Description }
{ 60 ;TextBox ;7980 ;0 ;1680 ;423 ;HorzAlign=Left;
FontSize=9;
// Add the following lines.
SourceExpr=FORMAT(DueDate,0,4);
DataSetFieldName=VendorLedgEntry2__Due_Date_ }
{ 61 ;TextBox ;13230;0 ;2310 ;423 ;FontSize=9;
SourceExpr=RemainingAmount;
// End of the added lines.
AutoFormatType=1;
AutoFormatExpr="Currency Code";
DataSetFieldName=VendorLedgEntry2__Remaining_Amount_ }
{ 62 ;TextBox ;15750;0 ;2310 ;423 ;FontSize=9;
... -
Modificați codul din Global variabilele din raportul de respectare a distribuitorului (13377) după cum urmează:
Cod existent 1...Text000@1000 : TextConst 'ENU=Page %1';
Text001@1001 : TextConst 'ENU=Open Entries %1';
Text002@1002 : TextConst 'ENU=Overdue Entries %1';
Text003@1003 : TextConst 'ENU="Statement "';
GLSetup@1004 : Record 98;
CompanyInfo@1005 : Record 79;
Vend2@1006 : Record 23;
Currency@1007 : Record 4;
...Înlocuirea cod 1
...Text000@1000 : TextConst 'ENU=Page %1';
Text001@1001 : TextConst 'ENU=Open Entries %1';
Text002@1002 : TextConst 'ENU=Overdue Entries %1';
Text003@1003 : TextConst 'ENU="Statement "';
// Add the following lines.
Text005@1030 : TextConst 'ENU=Multicurrency Application';
Text006@1031 : TextConst 'ENU=Payment Discount';
Text007@1032 : TextConst 'ENU=Rounding';
Text014@1033 : TextConst 'ENU=Application Writeoffs';
// End of the added lines.
GLSetup@1004 : Record 98;
CompanyInfo@1005 : Record 79;
Vend2@1006 : Record 23;
Currency@1007 : Record 4;
...Cod existent 2
...PrintAllHavingEntry@1010 : Boolean;
PrintAllHavingBal@1011 : Boolean;
PrintEntriesDue@1012 : Boolean;
PrintLine@1013 : Boolean;
StartDate@1014 : Date;
EndDate@1015 : Date;
VendAddr@1016 : ARRAY [8] OF Text[50];
CompanyAddr@1017 : ARRAY [8] OF Text[50];
...Înlocuirea cod 2
...
PrintAllHavingEntry@1010 : Boolean;
PrintAllHavingBal@1011 : Boolean;
PrintEntriesDue@1012 : Boolean;
PrintLine@1013 : Boolean;
// Add the following line.
DueDate@1038 : Date;
// End of the added line.
StartDate@1014 : Date;
EndDate@1015 : Date;
VendAddr@1016 : ARRAY [8] OF Text[50];
CompanyAddr@1017 : ARRAY [8] OF Text[50];
...Cod existent 3
...StartDate@1014 : Date;
EndDate@1015 : Date;
VendAddr@1016 : ARRAY [8] OF Text[50];
CompanyAddr@1017 : ARRAY [8] OF Text[50];
StartBalance@1018 : Decimal;
VendBalance@1019 : Decimal;
FormatAddr@1020 : Codeunit 365;
CurrencyCode3@1022 : Code[10];
...Înlocuirea cod 3
...StartDate@1014 : Date;
EndDate@1015 : Date;
VendAddr@1016 : ARRAY [8] OF Text[50];
CompanyAddr@1017 : ARRAY [8] OF Text[50];
// Add the following lines.
Description@1039 : Text[50];
RemainingAmount@1040 : Decimal;
// End of the added lines.
StartBalance@1018 : Decimal;
VendBalance@1019 : Decimal;
FormatAddr@1020 : Codeunit 365;
CurrencyCode3@1022 : Code[10];
...Cod existent 4
... </ReportItems>
</TableCell>
</TableCells>
<Visibility>
// Delete the following line.
<Hidden>=IIF(Fields!Vendor_Ledger_Entry_Vendor_No_.Value = "",TRUE,FALSE)</Hidden>
// End of the deleted line.
</Visibility>
</TableRow>
</TableRows>
</Details>
...Înlocuirea cod 4
...</ReportItems>
</TableCell>
</TableCells>
<Visibility>
// Add the following line.
<Hidden>=IIF(Fields!DtldVendLedgEntry_Vendor_No_.Value = "",TRUE,FALSE)</Hidden>
// End of the added line.
</Visibility>
</TableRow>
</TableRows>
</Details>
...Cod existent 5
...<FontWeight>700</FontWeight>
<TextAlign>Right</TextAlign>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Delete the following line.
<Value>=iif(Last(Fields!Vendor_Ledger_Entry_Vendor_No_.Value) = "" ,Last(Fields!VendBalance_Control66Caption.Value),
// End of the deleted line.
Last(Fields!VendBalance_Control53Caption.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Înlocuirea cod 5
...<FontWeight>700</FontWeight>
<TextAlign>Right</TextAlign>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Add the following line.
<Value>=iif(Last(Fields!DtldVendLedgEntry_Vendor_No_.Value) = "" ,Last(Fields!VendBalance_Control66Caption.Value),
// End of the added line.
Last(Fields!VendBalance_Control53Caption.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Cod existent 6
...<FontWeight>700</FontWeight>
<TextAlign>Right</TextAlign>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Delete the following line.
<Value>=iif(Last(Fields!Vendor_Ledger_Entry_Vendor_No_.Value) = "" ,Last(Fields!CurrencyCode3_Control73.Value),
// End of the deleted line.
Last(Fields!CurrencyCode3.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Înlocuirea cod 6
... <FontWeight>700</FontWeight>
<TextAlign>Right</TextAlign>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Add the following line.
<Value>=iif(Last(Fields!DtldVendLedgEntry_Vendor_No_.Value) = "" ,Last(Fields!CurrencyCode3_Control73.Value),
// End of the added line.
Last(Fields!CurrencyCode3.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Cod existent 7
...FontWeight>700</FontWeight>
<Format>=Fields!VendBalance_Control49Format.Value</Format>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Delete the following line.
<Value>=iif(Last(Fields!Vendor_Ledger_Entry_Vendor_No_.Value) = "" ,Last(Fields!VendBalance_Control56.Value),
// End of the deleted line.
LAST(Fields!VendBalance.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Înlocuirea cod 7
...<FontWeight>700</FontWeight>
<Format>=Fields!VendBalance_Control49Format.Value</Format>
<VerticalAlign>Middle</VerticalAlign>
</Style>
// Add the following line.
<Value>=iif(Last(Fields!DtldVendLedgEntry_Vendor_No_.Value) = "" ,Last(Fields!VendBalance_Control56.Value),
// End of the added line.
LAST(Fields!VendBalance.Value))</Value>
</Textbox>
</ReportItems>
</TableCell>
...Cod existent 8
...</Field>
<Field Name="CurrencyCode3">
<DataField>CurrencyCode3</DataField>
</Field>
// Delete the following lines.
<Field Name="Vendor_Ledger_Entry_Entry_No_">
<DataField>Vendor_Ledger_Entry_Entry_No_</DataField>
</Field>
<Field Name="Vendor_Ledger_Entry_Vendor_No_">
<DataField>Vendor_Ledger_Entry_Vendor_No_</DataField>
// End of the deleted lines.
</Field>
<Field Name="STRSUBSTNO_Text002_Currency2_Code_">
<DataField>STRSUBSTNO_Text002_Currency2_Code_</DataField>
</Field>
...Înlocuirea cod 8
...</Field>
<Field Name="CurrencyCode3">
<DataField>CurrencyCode3</DataField>
</Field>
// Add the following lines.
<Field Name="DtldVendLedgEntry_Entry_No_">
<DataField>DtldVendLedgEntry_Entry_No_</DataField>
</Field>
<Field Name="DtldVendLedgEntry_Vendor_No_">
<DataField>DtldVendLedgEntry_Vendor_No_</DataField>
// End of the added lines.
</Field>
<Field Name="STRSUBSTNO_Text002_Currency2_Code_">
<DataField>STRSUBSTNO_Text002_Currency2_Code_</DataField>
</Field>
...
Cerințe preliminare
Trebuie să aveți unul dintre următoarele produse instalate pentru a aplica această remediere rapidă:
-
Portugheză-versiunea de Microsoft Dynamics NAV 2009 R2
-
Versiunea portugheză Microsoft Dynamics NAV 2009 SP1
Eliminare informaţii
Nu se poate elimina această remediere rapidă.
Stare
Microsoft a confirmat că aceasta este o problemă cu produsele Microsoft enumerate în secţiunea „Se aplică la".
Notă Acesta este un articol "rapid publicat" creat direct în cadrul organizației de asistență Microsoft. Informațiile conținute în acest document sunt furnizate ca răspuns la problemele care apar. Ca rezultat al vitezei în a-l face disponibil, materialele pot include erori tipografice și pot fi revizuite în orice moment, fără notificare. Consultați Termenii de utilizarepentru alte considerații.