How do you block negative stock ?

When you key in a sales order a quantity higher that what you have in stock, you get a warning (Form 342), but you can ignore it and then deliver and invoice the quantity. Is there a way to stop the user from delivering more than what’s in stock ? There is a Negative Stock Yes/No field in XAL but I don’t see it in Financials.

Basically it is possible to set “Yes” button’s (on that Form 342) visibility property to false . But there must be some neater ways, which I leave on local craftsmans. Edited by - karel2 on 2001 Aug 07 13:19:27

I know about this solution, but if you hide the Yes button, then you cannot book in the sales order for the total quantity. Which means that you take away the ability of selling when you have no stock. Anyone got another idea ?

I have modified codeunit 22 for one customer. It’s very simple somewhere put code:

IF rec32.Open THEN 
  ERROR('This copmany don't sell a air');

In this way you will not able post invoice while out of stock.

When a user modify the quantity to ship and invoice, check the available quantity in stock. quantity to ship and invoice canno’t upper to the available quantity in stock

Yes, you cannot invoice more than you have delivered. But you can deliver even if you have no stock (that was my problem).

I am agree with you. With this system the quantity to ship in the order is equal or lower than the quantity in stock,you don’t have negative quantity in stock.

Hi We have created a field on the Item Card (Item Table, 27) “Allow Neg. Inventory”. This field is only marked (Yes/No) if a Inventory (by location/Shelf Bin No.) is allowed for this particular Item. Every time You book something, the system makes the check. Mads Morre Scanvaegt International - DK

Hi We call “ItemCheckAvail” function in “Item Jnl.-Check Line” to disable all postings causing negative stock. frank

Is there a way to have the stock out warning appear at the time of posting the shipment? We only get the message when we enter the order or when we do inventory adjustment.

Hi, Knowlton - without coding it is not possible, nevertheless it is not too hard to add this check in Codeunit 80, Sales-Post, basically adapting the functions that are used in Form 342 Check Availability - you cannot directly call that Form from the posting codeunit, leads to an error… But watch out, Codeunit 80, is one of the most complex codeunits in Navision… Frank… I had a look at “Item Jnl.-Check Line” and this looks like a customization, because I couldn’t find that function. Saludos Nils

About Fabrice method: You can accept orders for a quantity higher than the one you’re having on stock, but waiting to ship them until receiving the quantity from your vendors. Your method will disable this, as it would not allow to enter orders with quantity higher than the one on stock. :frowning: If you don’t want to let a sales order being delivered why don’t you just modify the codeunit 80 for checking before starting the posting process if all the items on the order you’re posting have enough quantity on hand for filling the qty. to ship?? It’s easy, fast and effective when using sales orders. If you’re wanting to keep track also by restricting the item journals, modify also codeunit 22. Regards Alfonso Pertierra (Spain)