BPM to Receive Job to Inventory - Specify Serial Number

I’m about 80% complete with a BPM that will receive a job to inventory by following the methods called when going to Job Receipt to Inventory. I’m stuck on the part where I tell it which serial number(s) go along with the transaction. Most of the methods appear to be related to generating the on-screen UX. I don’t need to replicate that (do I?)… I just need to tell it which serial number to use. Programmatically, I can get the right serial number.

How do I stuff it into the Selected Serial Numbers table in the ReceiptsFromMfg dataset?

Well, ran into another issue… I guess the ReceiptsFromMfg dataset contains some of the same tables as dsCustShip. And it is throwing an error when I try to enable the BPM. I guess I’ve never tried anything like this before… is there a workaround for this?

Server Side Exception

There is at least one compilation error.
GetQtyInfo.CommonTypes.cs(279,33): error CS0433: The type ‘LegalNumGenOptsTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
GetQtyInfo.CommonTypes.cs(294,33): error CS0433: The type ‘SelectedSerialNumbersTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
GetQtyInfo.CommonTypes.cs(304,33): error CS0433: The type ‘SNFormatTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
CustomizationAdapter.cs(484,30): error CS0433: The type ‘SelectSerialNumbersParamsTableset’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
CustomizationAdapter.cs(9,138): error CS0738: ‘CustShipSvcCustomization’ does not implement interface member ‘CustShipSvcContract.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’. ‘CustShipSvcCustomization.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’ cannot implement ‘CustShipSvcContract.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’ because it does not have the matching return type of ‘SelectSerialNumbersParamsTableset’.

Exception caught in: Epicor.ServiceModel

Error Detail
============
Description: There is at least one compilation error.
Details:
GetQtyInfo.CommonTypes.cs(279,33): error CS0433: The type ‘LegalNumGenOptsTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
GetQtyInfo.CommonTypes.cs(294,33): error CS0433: The type ‘SelectedSerialNumbersTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
GetQtyInfo.CommonTypes.cs(304,33): error CS0433: The type ‘SNFormatTable’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
CustomizationAdapter.cs(484,30): error CS0433: The type ‘SelectSerialNumbersParamsTableset’ exists in both ‘Erp.Contracts.BO.CustShip, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’ and ‘Erp.Contracts.BO.ReceiptsFromMfg, Version=10.2.300.0, Culture=neutral, PublicKeyToken=5d3fa3c7105d7992’
CustomizationAdapter.cs(9,138): error CS0738: ‘CustShipSvcCustomization’ does not implement interface member ‘CustShipSvcContract.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’. ‘CustShipSvcCustomization.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’ cannot implement ‘CustShipSvcContract.GetSelectSerialNumbersParams(string, decimal, string, int, int, string, string, string, string, string, bool, int, int, int, Guid)’ because it does not have the matching return type of ‘SelectSerialNumbersParamsTableset’.
Program: Epicor.Customization.Core.dll
Method: Compile
Line Number: 78
Column Number: 13

Client Stack Trace
==================
at Epicor.ServiceModel.Channels.ImplBase`1.ShouldRethrowNonRetryableException(Exception ex, DataSet dataSets)
at Ice.Proxy.BO.BpMethodImpl.Update(BpMethodDataSet ds)
at Ice.Adapters.BpMethodAdapter.OnUpdate()
at Ice.Lib.Framework.EpiBaseAdapter.Update()
at Ice.UI.App.BpMethodEntry.Transactions.MainTransactionBase.adapterUpdate()

There was an old post here describing this issue but can’t find it now. What I did is I created another library and then called that from my main one.

I found your post I think when I was looking around for this. I don’t want to create a new library. That sounds scary :slight_smile: .

I’m trying a workaround where I set the Auto Receive checkbox to be true on the final operation and then it will automatically receive itself into inventory so I don’t have to force it. For some reason, we have that checkbox disabled by default. Is there any reason why we wouldn’t want to auto receive to inventory?

We don’t use Auto Receive either so I haven’t played with it. But I am sure somebody who does around here can help you. I know there were some issues with it in the old versions, maybe they’re fixed now.

We had AutoReceive disabled because when we were on 10.2.300 (at the time of my posting) there was a bug where Serial Tracked parts that were auto-receive = true would get the SN Status changed to Inventory even if the job demand link was make to order … so the system interpreted the quantity properly and did not receive it into inventory but it changed the SN Status. So we had a BPM in place to prevent someone from marking AutoReceive on serial tracked parts. That seems to have been resolved now that were on 2021.2.