Update SerialNo.SNReference

I need to update SerialNo.SNReference programmatically. I am not sure how to approach this. Should I use a service contract with Erp.Proxy.BO.SerialNoImpl implementation, use an epiDataView, or is there something else all together that I can use?

Hi Joel,

How about a bpm? Do you have an event you can work with?


Not yet but I will look at that.

Still being relatively new to Epicor, I have realized that I don’t really understand the implementation of BPMs. I ended up getting the job done by doing this.

var session = (Ice.Core.Session)oTrans.Session;
using (var svc = WCFServiceSupport.CreateImpl<Erp.Proxy.BO.SerialNoImpl>(session, Epicor.ServiceModel.Channels.ImplBase<Erp.Contracts.SerialNoSvcContract>.UriPath)){
bool bSerialNumberExists = false;
bool bMorePages = false;
SerialNoDataSet dsSerialNumberData = new SerialNoDataSet();
svc.SerialNumberExists(strSNBeingAdded, out bSerialNumberExists);

string strSN = "SerialNumber =  '" + strSNBeingAdded + "' BY SerialNumber";
if (bSerialNumberExists)
	dsSerialNumberData = svc.GetRows(strSN, "", "", 0, 0, out bMorePages);	
	dsSerialNumberData.SerialNo[0].SerialNumber = strSNBeingAdded;	
	dsSerialNumberData.SerialNo[0].FSServiceLevelAgreement = strPassFailData;
	dsSerialNumberData.SerialNo[0].SNReference = strTestResult;
	dsSerialNumberData.SerialNo[0].TransactionSource = "SNMaint";