David Captur
09/09/2024, 2:10 PMCeligo AI
09/09/2024, 2:10 PMAI generated answer (using internal Slack threads):In order to replicate your Inventory Balance saved search in C#.net using the SOAP API, you would need to use the
ItemSearchBasic
and InventoryNumberSearchBasic
search types.
The ItemSearchBasic
allows you to search for items, and you can filter by location to get the items available in a specific location. The InventoryNumberSearchBasic
allows you to search for inventory numbers, which can be used to get serialized and non-serialized stock.
Here is a rough example of how you might structure your search:
csharp
ItemSearchBasic itemSearch = new ItemSearchBasic();
itemSearch.location = new SearchMultiSelectField();
itemSearch.location.operator = SearchMultiSelectFieldOperator.anyOf;
itemSearch.location.searchValue = new RecordRef[] { new RecordRef() { internalId = "your_location_id" } };
InventoryNumberSearchBasic inventorySearch = new InventoryNumberSearchBasic();
inventorySearch.item = new SearchMultiSelectField();
inventorySearch.item.operator = SearchMultiSelectFieldOperator.anyOf;
inventorySearch.item.searchValue = new RecordRef[] { new RecordRef() { internalId = "your_item_id" } };
SearchRequest request = new SearchRequest();
request.searchRecord = itemSearch;
SearchResponse response = _service.search(request);
Please replace "your_location_id"
and "your_item_id"
with your actual location and item IDs.
Remember to handle the response properly and iterate over the result set to get your inventory balance.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
09/09/2024, 2:11 PMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.852713466
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.851756632
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.850909173
Celigo AI
09/09/2024, 2:11 PMCeligo AI
09/09/2024, 2:16 PMCeligo AI
09/09/2024, 2:16 PM