Skip to content

Instantly share code, notes, and snippets.

@chadsten
Created March 17, 2017 18:27
Show Gist options
  • Save chadsten/5bd0e3912f32d1fd5151d0b300133111 to your computer and use it in GitHub Desktop.
Save chadsten/5bd0e3912f32d1fd5151d0b300133111 to your computer and use it in GitHub Desktop.
Erp.Tables.Vendor Vendor;foreach (var ttPO_Row in (from ttPO_Iter in ttPOHeader select ttPO_Iter)){ if (ttPO_Row != null) {this.PublishInfoMessage("PO ROW", Ice.Common.BusinessObjectMessageType.Information, Ice.Bpm.InfoMessageDisplayMode.Individual, "PO", "Trans");  // load Vendor record, if it exists  var Vendor_Row = (from Vendor_Iter in Db.Vendor where ttPO_Row.Company == Vendor_Iter.Company && ttPO_Row.VendorNum == Vendor_Iter.VendorNum select Vendor_Iter).FirstOrDefault();  if (Vendor_Row == null)  {this.PublishInfoMessage("VENDOR ROW", Ice.Common.BusinessObjectMessageType.Information, Ice.Bpm.InfoMessageDisplayMode.Individual, "PO", "Trans");   // set the PO freight target equal to the current vendor freight target   ttPO_Row.SetUDField<System.Decimal>("FreightTarget_c", Vendor_Row.UDField<System.Decimal>("FreightTarget_c"));  } }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment