Hello, I'm getting a weird error when creating a new item via BOI. I'm able to create it in CI_Item without issue. But when I go to add data to the IM_ItemVendor or IM_AliasItem tables I'm getting an error that reads: "B/M is not on file". I don't know what this error means, as we don't use Bill of Materials (I think that's what it is referencing). I'm using this via a C# interface. Here's some sample code for you to see what's going on. Assume that I have an initialized pvx object. TaskID = (int)oSS.InvokeMethod("nLookupTask", "IM_ItemVendor_ui"); oSS.InvokeMethod("nSetProgram", TaskID); using (DispatchObject IMItemVendor = new DispatchObject(pvx.InvokeMethod("NewObject", "IM_ItemVendor_bus", oSS.GetObject()))) { string key = String.Format("{0}00{1}", newSku.ItemCode, newSku.VendorNo); IMItemVendor.InvokeMethod("nSetKey", key); IMItemVendor.InvokeMethod("nSetValue", "LastUnitCost", newSku.Cost); int success = (int)IMItemVendor.InvokeMethod("nWrite"); if (Math.Abs(success) != 1) { this._errorDescription = "Error saving Item Vendor"; this._exception = new Exception((string)oSS.InvokeMethod("sLastErrorMsg")); return false; } } Hopefully one of you have seen this issue before. Any help troubleshooting is much appreciated. Thanks! jared
↧