Error while posting Purchase Order with Item charges

toshitapori
Member Posts: 52
Hello,
I am using Nav 3.70 with sql. The problem i am having is as follows. If i create a purchase order and assign Item charges by amount for the lines entered i am unable to post the purchase order from the warehouse receipt created. It comes up with error message saying you cannot assign more than 0 units in Doc Type=xxx, Doc no=xxx, Line No.=xxx.
Can any body explain me why i am getting this error or if someone has see this kind of error. I tried to post a purchase order where location on purchase line is not warehouse location and it allows me to post the PO with item charges but not in the case where i have a warehouse managed location. Moreover i tried it in version 5 and it allows me to post the PO with item charges assignment by amount. So i tried to compare the codeunit 90 for both the version and could not figure out anything different.
In 3.70 it falls at the point in codeunit 90 in the function CopyAndCheckItemCharge
IF ABS(PurchLine2."Qty. to Assign" + PurchLine2."Qty. Assigned") >
ABS(PurchLine2."Qty. to Invoice" + PurchLine2."Quantity Invoiced")
THEN
ERROR(Text036,
PurchLine2."Qty. to Invoice" + PurchLine2."Quantity Invoiced" -
PurchLine2."Qty. Assigned",PurchLine2.FIELDCAPTION("Document Type"),
PurchLine2."Document Type",PurchLine2.FIELDCAPTION("Document No."),
PurchLine2."Document No.",PurchLine2.FIELDCAPTION("Line No."),
PurchLine2."Line No.");
Can someone please suggest me what is wrong ???? Is it a bug in 3.70 ???
rgds.
toshitapori
I am using Nav 3.70 with sql. The problem i am having is as follows. If i create a purchase order and assign Item charges by amount for the lines entered i am unable to post the purchase order from the warehouse receipt created. It comes up with error message saying you cannot assign more than 0 units in Doc Type=xxx, Doc no=xxx, Line No.=xxx.
Can any body explain me why i am getting this error or if someone has see this kind of error. I tried to post a purchase order where location on purchase line is not warehouse location and it allows me to post the PO with item charges but not in the case where i have a warehouse managed location. Moreover i tried it in version 5 and it allows me to post the PO with item charges assignment by amount. So i tried to compare the codeunit 90 for both the version and could not figure out anything different.
In 3.70 it falls at the point in codeunit 90 in the function CopyAndCheckItemCharge
IF ABS(PurchLine2."Qty. to Assign" + PurchLine2."Qty. Assigned") >
ABS(PurchLine2."Qty. to Invoice" + PurchLine2."Quantity Invoiced")
THEN
ERROR(Text036,
PurchLine2."Qty. to Invoice" + PurchLine2."Quantity Invoiced" -
PurchLine2."Qty. Assigned",PurchLine2.FIELDCAPTION("Document Type"),
PurchLine2."Document Type",PurchLine2.FIELDCAPTION("Document No."),
PurchLine2."Document No.",PurchLine2.FIELDCAPTION("Line No."),
PurchLine2."Line No.");
Can someone please suggest me what is wrong ???? Is it a bug in 3.70 ???
rgds.
toshitapori
0
Comments
-
At the point where the debugger stops, what are the current values for Qty To Assign, Qty Assigned, Qty to Invoice, and Quantity Invoiced?
No one loves you like the one who created you...0 -
Hi Saint,
The values are like this 1+0 > 0+0 for the corresponding fields. Now i am wondering why is Qty to Invoice = 0 as i have specified qty as 1 in the line of type Item(Charge). After i try to post the warehouse recipt it blanks the qty to invoice to zero so thats why i am getting the error message bcoz the if condition gets true but the imp question here is that i am doing it on standard 3.70 and the code is not modified so why it is falling over????
rgds,
toshitapori0 -
I guess there might be a bug that it sets the qty to receive to 0 at warehousing locations not only for line type= item but also for item charge. And qty. to receive in turn sets qty. to invoice to 0.
It's almost surely somewhere in table 39 - in 5.0 there is a function called UpdateWarehouseReceive in table 39, there must be something like that in 3.7 as well. Search the code in table 39 for Qty. to Receive and tell it to do it only if it's an Item.0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions