Click or drag to resize

ItemServicesConsumeItem Method

Consumes the specified quantity of material from the specified Item. Only items with a Classification of Part can be consumed.

Namespace:  FactoryLogix.xTend.Logistics
Assembly:  FactoryLogix.xTend.API (in FactoryLogix.xTend.API.dll) Version: 8.242.0.0 (8.242.0.0)
Syntax
public void ConsumeItem(
	Guid sessionId,
	Guid itemId,
	double quantity,
	string batchName
)

Parameters

sessionId
Type: SystemGuid
The session identifier that was returned by the Connect(String, String, String, String, String) method.
itemId
Type: SystemGuid
An Item object representing the new item to be processed.
quantity
Type: SystemDouble
The quantity of material to be consumed from the Item. If the amount specified exceeds the amount remaining, the quantity of Item will be set to zero, but the specified amound consumed will be recorded in the history.
batchName
Type: SystemString
An optional parameter specifying the production work order (batch) that the consumption should be charged against.
Exceptions
ExceptionCondition
ArgumentExceptionThrown if some of provided parameters is invalid.
InvalidSessionExceptionThrown if the sessionId parameter is invalid.
NotFoundExceptionThrown if an Item matching the itemId parameter does not exist.
BatchNotFoundExceptionThrown if the batchName parameter is not null or empty, and specifies a production batch that does not exist.
InvalidItemClassificationExceptionThrown if the Item is not a Part classification.
See Also