RE: User event script for Receive Inbound Shipment
I created a simple user event script forĀ Receive Inbound Shipment:
function beforeLoad(type,form)
{
for (var i = 1; i <= nlapiGetLineItemCount('receiveitems'); i++)
{
nlapiSetLineItemValue('receiveitems','quantitytobereceived',i,1);
nlapiSetLineItemValue('receiveitems','receiveitem',i, 'F');
}
}
Checkbox ‘receiveitem’ work correct, but setting value ‘1’ for field ‘quantitytobereceived’ doesn’t work. Can anybody help with this problem?
Any chance it isn’t working because the inventory detail is not configured?
I can change value in ‘ quantitytobereceived’ manually.