Conectați-vă cu Microsoft
Conectați-vă sau creați un cont
Salut,
Selectați un alt cont.
Aveți mai multe conturi
Alegeți contul cu care doriți să vă conectați.

Acest articol se aplică la Microsoft Dynamics NAV pentru toate țările și toate limbi regionale.

Simptome

Aveți posibilitatea să creați o comandă de vânzări pentru un element blocat pentru a fi dintr-o ofertă de vânzări în Microsoft Dynamics 2009 în mod neașteptat. Când publicați comenzilor de vânzări, primiţi următorul mesaj de eroare:

Cantitatea livrate în comanda generală asociate nu trebuie să fie mai mare decât cantitatea în tipul de Document vânzări linie = 'Comandă generală', Document No.number1', linia No. =number2'.

Această problemă se produce în următoarele produse:

  • Microsoft Dynamics NAV 2009 Service Pack 1

  • Microsoft Dynamics NAV 2009 R2


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 Server de aplicație (NAS). Ar trebui să fie doar client utilizatorului care este conectat când implementați această remediere rapidă.

Pentru a implementa această remediere rapidă, trebuie să aibă o licență pentru dezvoltatori.

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 de 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 remediază într-un mediu controlat înainte de a aplica remedieri pentru computerele de producție.

Pentru a rezolva această problemă, urmați acești pași:

  1. Modificați codul din proprietățile în vânzări-ofertă ordinea Codeunit (86) după cum urmează:
    Cod existent 1

    ...Opp@1004 : Record 5092;

    OpportunityEntry@1006 : Record 5093;

    TempOpportunityEntry@1005 : TEMPORARY Record 5093;

    Cust@1008 : Record 18;

    BEGIN

    TESTFIELD("Document Type","Document Type"::Quote);

    Cust.GET("Sell-to Customer No.");

    Cust.CheckBlockedCustOnDocs(Cust,"Document Type"::Order,TRUE,FALSE);
    ...

    Înlocuirea cod 2

    ...Opp@1004 : Record 5092;

    OpportunityEntry@1006 : Record 5093;

    TempOpportunityEntry@1005 : TEMPORARY Record 5093;

    Cust@1008 : Record 18;

    // Add the following line.
    Item@1010 : Record 27;
    // End of the added line.

    BEGIN

    TESTFIELD("Document Type","Document Type"::Quote);

    Cust.GET("Sell-to Customer No.");

    Cust.CheckBlockedCustOnDocs(Cust,"Document Type"::Order,TRUE,FALSE);
    ...

    Cod existent 2

    ...SalesQuoteLine.SETRANGE(Type,SalesQuoteLine.Type::Item);

    SalesQuoteLine.SETFILTER("No.",'<>%1','');

    IF SalesQuoteLine.FINDSET THEN

    REPEAT

    IF (SalesQuoteLine."Outstanding Quantity" > 0) THEN BEGIN

    SalesLine := SalesQuoteLine;

    SalesLine.VALIDATE("Reserved Qty. (Base)",0);

    SalesLine."Line No." := 0;
    ...

    Înlocuirea cod 2

    ...SalesQuoteLine.SETRANGE(Type,SalesQuoteLine.Type::Item);

    SalesQuoteLine.SETFILTER("No.",'<>%1','');

    IF SalesQuoteLine.FINDSET THEN

    REPEAT

    IF Item.GET(SalesQuoteLine."No.") THEN //add line

    // Add the following line.
    Item.TESTFIELD(Blocked,FALSE);
    // End of the added line.

    IF (SalesQuoteLine."Outstanding Quantity" > 0) THEN BEGIN

    SalesLine := SalesQuoteLine;

    SalesLine.VALIDATE("Reserved Qty. (Base)",0);

    SalesLine."Line No." := 0;
    ...
  2. Modificați codul din proprietățile în comanda generală vânzări ordine Codeunit (87) după cum urmează:
    Cod existent 1

    ...Cust@1001 : Record 18;

    TempSalesLine@1002 : TEMPORARY Record 37;

    Reservation@1005 : Form 498;

    PrepmtMgt@1004 : Codeunit 441;

    BEGIN

    TESTFIELD("Document Type","Document Type"::"Blanket Order");

    Cust.GET("Sell-to Customer No.");

    Cust.CheckBlockedCustOnDocs(Cust,"Document Type"::Order,TRUE,FALSE);
    ...

    Cod de înlocuire 1

    ...Cust@1001 : Record 18;

    TempSalesLine@1002 : TEMPORARY Record 37;

    Reservation@1005 : Form 498;

    PrepmtMgt@1004 : Codeunit 441;

    // Add the following line.
    Item@1006 : Record 27;
    // End of the added line.

    BEGIN

    TESTFIELD("Document Type","Document Type"::"Blanket Order");

    Cust.GET("Sell-to Customer No.");

    Cust.CheckBlockedCustOnDocs(Cust,"Document Type"::Order,TRUE,FALSE);
    ...

    Cod existent 2

    ...SalesLine.SETRANGE("Blanket Order Line No.",BlanketOrderSalesLine."Line No.");

    QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    IF SalesLine."Document Type" IN

    [SalesLine."Document Type"::"Return Order",

    SalesLine."Document Type"::"Credit Memo"]

    THEN
    ...

    Înlocuirea cod 2

    ...SalesLine.SETRANGE("Blanket Order Line No.",BlanketOrderSalesLine."Line No.");

    QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    // Add the following lines.
    IF Item.GET(SalesLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    // End of the added lines.

    IF SalesLine."Document Type" IN

    [SalesLine."Document Type"::"Return Order",

    SalesLine."Document Type"::"Credit Memo"]

    THEN
    ...

    Cod existent 3

    ...TempSalesLine.DELETEALL;

    REPEAT

    SalesLine.SETCURRENTKEY("Document Type","Blanket Order No.","Blanket Order Line No.");

    SalesLine.SETRANGE("Blanket Order No.",BlanketOrderSalesLine."Document No.");

    SalesLine.SETRANGE("Blanket Order Line No.",BlanketOrderSalesLine."Line No.");

    // Delete the following lines.

    SalesLine.SETFILTER(

    "Document Type",'<>%1 & <>%2',SalesLine."Document Type"::Invoice,SalesLine."Document Type"::"Credit Memo");

    // End of the deleted lines.

    QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    IF Item.GET(SalesLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    ...

    Cod de înlocuire 3

    ...TempSalesLine.DELETEALL;

    REPEAT

    SalesLine.SETCURRENTKEY("Document Type","Blanket Order No.","Blanket Order Line No.");

    SalesLine.SETRANGE("Blanket Order No.",BlanketOrderSalesLine."Document No.");

    SalesLine.SETRANGE("Blanket Order Line No.",BlanketOrderSalesLine."Line No.");

    QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    IF Item.GET(SalesLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    ...

    Cod existent 4

    ...QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    IF Item.GET(SalesLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);

    // Delete the following lines.
    IF SalesLine."Document Type" = SalesLine."Document Type"::"Return Order" THEN
    QuantityOnOrders := QuantityOnOrders - SalesLine."Outstanding Qty. (Base)"

    ELSE //Remove line

    QuantityOnOrders := QuantityOnOrders + SalesLine."Outstanding Qty. (Base)";
    // End of the deleted lines.

    UNTIL SalesLine.NEXT = 0;

    IF (ABS(BlanketOrderSalesLine."Qty. to Ship (Base)" + QuantityOnOrders +

    BlanketOrderSalesLine."Qty. Shipped (Base)") >

    ABS(BlanketOrderSalesLine."Quantity (Base)")) OR

    (BlanketOrderSalesLine."Quantity (Base)" * BlanketOrderSalesLine."Outstanding Qty. (Base)" < 0)
    ...

    Înlocuirea cod 4

    ...QuantityOnOrders := 0;

    IF SalesLine.FINDSET THEN

    REPEAT

    IF Item.GET(SalesLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);

    // Add the following lines.

    IF (SalesLine."Document Type" = SalesLine."Document Type"::"Return Order") OR

    ((SalesLine."Document Type" = SalesLine."Document Type"::"Credit Memo") AND

    (SalesLine."Return Receipt No." = ''))

    THEN

    QuantityOnOrders := QuantityOnOrders - SalesLine."Outstanding Qty. (Base)"

    ELSE

    IF (SalesLine."Document Type" = SalesLine."Document Type"::Order) OR

    ((SalesLine."Document Type" = SalesLine."Document Type"::Invoice) AND

    (SalesLine."Shipment No." = ''))

    THEN

    QuantityOnOrders := QuantityOnOrders + SalesLine."Outstanding Qty. (Base)";

    // End of the added lines.

    UNTIL SalesLine.NEXT = 0;

    IF (ABS(BlanketOrderSalesLine."Qty. to Ship (Base)" + QuantityOnOrders +

    BlanketOrderSalesLine."Qty. Shipped (Base)") >

    ABS(BlanketOrderSalesLine."Quantity (Base)")) OR

    (BlanketOrderSalesLine."Quantity (Base)" * BlanketOrderSalesLine."Outstanding Qty. (Base)" < 0)
    ...
  3. Modificați codul din proprietățile în cump.-citat la ordinea Codeunit (96) după cum urmează:
    Cod existent 1

    ...OldPurchCommentLine@1001 : Record 43;

    FromDocDim@1000 : Record 357;

    ToDocDim@1003 : Record 357;

    Vend@1002 : Record 23;

    BEGIN

    TESTFIELD("Document Type","Document Type"::Quote);

    Vend.GET("Buy-from Vendor No.");

    Vend.CheckBlockedVendOnDocs(Vend,FALSE);
    ...

    Cod de înlocuire 1

    ...OldPurchCommentLine@1001 : Record 43;

    FromDocDim@1000 : Record 357;

    ToDocDim@1003 : Record 357;

    Vend@1002 : Record 23;

    // Add the following line.
    Item@1004 : Record 27;
    // End of the added line.

    BEGIN

    TESTFIELD("Document Type","Document Type"::Quote);

    Vend.GET("Buy-from Vendor No.");

    Vend.CheckBlockedVendOnDocs(Vend,FALSE);

    Cod existent 2

    ...ToDocDim.SETRANGE("Table ID",DATABASE::"Purchase Line");



    IF PurchQuoteLine.FINDSET THEN

    REPEAT

    PurchOrderLine := PurchQuoteLine;

    PurchOrderLine."Document Type" := PurchOrderHeader."Document Type";

    PurchOrderLine."Document No." := PurchOrderHeader."No.";

    ReservePurchLine.TransferPurchLineToPurchLine(
    ...

    Înlocuirea cod 2

    ...ToDocDim.SETRANGE("Table ID",DATABASE::"Purchase Line");



    IF PurchQuoteLine.FINDSET THEN

    REPEAT

    // Add the following lines.
    IF Item.GET(PurchQuoteLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    // End of the added lines.

    PurchOrderLine := PurchQuoteLine;

    PurchOrderLine."Document Type" := PurchOrderHeader."Document Type";

    PurchOrderLine."Document No." := PurchOrderHeader."No.";

    ReservePurchLine.TransferPurchLineToPurchLine(
    ...
  4. Modificați codul din proprietățile în cump generală. Pentru a comanda Codeunit (97) după cum urmează:
    Cod existent 1

    ...FromDocDim@1000 : Record 357;

    ToDocDim@1002 : Record 357;

    Vend@1001 : Record 23;

    PrepmtMgt@1003 : Codeunit 441;

    BEGIN

    TESTFIELD("Document Type","Document Type"::"Blanket Order");

    Vend.GET("Buy-from Vendor No.");

    Vend.CheckBlockedVendOnDocs(Vend,FALSE);
    ...

    Cod de înlocuire 1

    ...FromDocDim@1000 : Record 357;

    ToDocDim@1002 : Record 357;

    Vend@1001 : Record 23;

    PrepmtMgt@1003 : Codeunit 441;

    // Add the following line.
    Item@1004 : Record 27;
    // End of the added line.

    BEGIN

    TESTFIELD("Document Type","Document Type"::"Blanket Order");

    Vend.GET("Buy-from Vendor No.");

    Vend.CheckBlockedVendOnDocs(Vend,FALSE);
    ...

    Cod existent 2

    ...PurchLine.SETRANGE("Blanket Order Line No.",PurchBlanketOrderLine."Line No.");

    QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    IF PurchLine."Document Type" IN

    [PurchLine."Document Type"::"Return Order",

    PurchLine."Document Type"::"Credit Memo"] THEN

    QuantityOnOrders := QuantityOnOrders - PurchLine."Outstanding Qty. (Base)"
    ...

    Înlocuirea cod 2

    ...PurchLine.SETRANGE("Blanket Order Line No.",PurchBlanketOrderLine."Line No.");

    QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    // Add the following lines.
    IF Item.GET(PurchLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    // End of the added lines.

    IF PurchLine."Document Type" IN

    [PurchLine."Document Type"::"Return Order",

    PurchLine."Document Type"::"Credit Memo"] THEN

    QuantityOnOrders := QuantityOnOrders - PurchLine."Outstanding Qty. (Base)"
    ...

    Cod existent 3

    ...IF PurchBlanketOrderLine.FINDSET THEN

    REPEAT

    PurchLine.SETCURRENTKEY("Document Type","Blanket Order No.","Blanket Order Line No.");

    PurchLine.SETRANGE("Blanket Order No.",PurchBlanketOrderLine."Document No.");

    PurchLine.SETRANGE("Blanket Order Line No.",PurchBlanketOrderLine."Line No.");

    // Delete the following lines.

    PurchLine.SETFILTER(

    "Document Type",'<>%1 & <>%2',PurchLine."Document Type"::Invoice,PurchLine."Document Type"::"Credit Memo");

    // End of the deleted lines.

    QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    IF Item.GET(PurchLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    ...

    Cod de înlocuire 3

    ...IF PurchBlanketOrderLine.FINDSET THEN

    REPEAT

    PurchLine.SETCURRENTKEY("Document Type","Blanket Order No.","Blanket Order Line No.");

    PurchLine.SETRANGE("Blanket Order No.",PurchBlanketOrderLine."Document No.");

    PurchLine.SETRANGE("Blanket Order Line No.",PurchBlanketOrderLine."Line No.");

    QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    IF Item.GET(PurchLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);
    ...

    Cod existent 4

    ...QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    IF Item.GET(PurchLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);

    // Delete the following lines.

    IF PurchLine."Document Type" = PurchLine."Document Type"::"Return Order" THEN

    QuantityOnOrders := QuantityOnOrders - PurchLine."Outstanding Qty. (Base)"

    ELSE

    QuantityOnOrders := QuantityOnOrders + PurchLine."Outstanding Qty. (Base)";

    // End of the deleted lines.

    UNTIL PurchLine.NEXT = 0;

    IF (ABS(PurchBlanketOrderLine."Qty. to Receive (Base)" + QuantityOnOrders +

    PurchBlanketOrderLine."Qty. Received (Base)") >

    ABS(PurchBlanketOrderLine."Quantity (Base)")) OR

    (PurchBlanketOrderLine."Quantity (Base)" * PurchBlanketOrderLine."Outstanding Qty. (Base)" < 0)
    ...

    Înlocuirea cod 4

    ...QuantityOnOrders := 0;

    IF PurchLine.FINDSET THEN

    REPEAT

    IF Item.GET(PurchLine."No.") THEN

    Item.TESTFIELD(Blocked,FALSE);

    // Add the following lines.

    IF (PurchLine."Document Type" = PurchLine."Document Type"::"Return Order") OR

    ((PurchLine."Document Type" = PurchLine."Document Type"::"Credit Memo") AND

    (PurchLine."Return Shipment No." = ''))

    THEN

    QuantityOnOrders := QuantityOnOrders - PurchLine."Outstanding Qty. (Base)"

    ELSE

    IF (PurchLine."Document Type" = PurchLine."Document Type"::Order) OR

    ((PurchLine."Document Type" = PurchLine."Document Type"::Invoice) AND

    (PurchLine."Receipt No." = ''))

    THEN

    QuantityOnOrders := QuantityOnOrders + PurchLine."Outstanding Qty. (Base)";
    // End of the added lines.

    UNTIL PurchLine.NEXT = 0;

    IF (ABS(PurchBlanketOrderLine."Qty. to Receive (Base)" + QuantityOnOrders +

    PurchBlanketOrderLine."Qty. Received (Base)") >

    ABS(PurchBlanketOrderLine."Quantity (Base)")) OR

    (PurchBlanketOrderLine."Quantity (Base)" * PurchBlanketOrderLine."Outstanding Qty. (Base)" < 0)
    ...


Cerințe preliminare

Trebuie să aveți următoarea actualizare și unul dintre următoarele produse instalate pentru a aplica această remediere rapidă:

  • Microsoft Dynamics NAV 2009 Service Pack 1

  • Microsoft Dynamics NAV 2009 R2

  • 2642368 comanda "Cantitate de livrare (baza) elementului [Item_Number] în linie nr. [Line_Number] nu poate fi mai mult decât [Number]" mesaj de eroare când încercați să creați o comandă la un generală în Microsoft Dynamics NAV

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.

Aveți nevoie de ajutor suplimentar?

Doriți mai multe opțiuni?

Explorați avantajele abonamentului, navigați prin cursurile de instruire, aflați cum să vă securizați dispozitivul și multe altele.

Comunitățile vă ajută să adresați întrebări și să răspundeți la întrebări, să oferiți feedback și să primiți feedback de la experți cu cunoștințe bogate.

Au fost utile aceste informații?

Cât de mulțumit sunteți de calitatea limbajului?
Ce v-a afectat experiența?
Apăsând pe Trimitere, feedbackul dvs. va fi utilizat pentru a îmbunătăți produsele și serviciile Microsoft. Administratorul dvs. IT va avea posibilitatea să colecteze aceste date. Angajamentul de respectare a confidențialității.

Vă mulțumim pentru feedback!

×