I am trying to add price break rows using code, it runs and there is no error, but when I open Supplier Price List, I don’t see the rows there! Am I doing anything wrong in my code?
VendPartImpl bo = WCFServiceSupport.CreateImpl(_session, Epicor.ServiceModel.Channels.ImplBase<Erp.Contracts.VendPartSvcContract>.UriPath);
VendPartDataSet ds = new VendPartDataSet();
Have you tried focusing on the correct capitalization of the system elements?
I understand that it matters to C# if you use “PartNum” not “partNum”. I see all your string variables as potential problems. And probably “bo.GetByID” will probably need to be “BO”.
See if that doesn’t help you.
Ben
If you try and comment out the second (or the first) ChangePriceModifier, does it work ? Also, if you try it with a part that does not have records in VendPBrk, does it work the first time ?
bo is an object I have instantiated in my code!! My code compiles! You do not see all the code here, click on the icon on top right to see the rest.
I have been coding for 20+ years professionally! If you are not sure what I am asking here it’s best if you didn’t make any input. Have a nice day!
Can you move everything into your Try block? (bo.ChangePriceIdentifier through bo.update()). While you’re not currently throwing an error, if you do, you’ll be able to get some reason. Whenever I’m doing array access, I find it’s possible to be out of range for example. If there is an existing record, you would want to check that as well. Might shed some light on what is happening.
Take a look at the event logs on the app server (that’s the windows event logs, not the server.txt). I have seen instances where no run-time errors are thrown to the UI but errors exist in the event logs.
The thing is it saves everything and when I load the vendor ID, in the code I can see all data is saved in the table in dataset, but when I run Epicor and open the same Vendor ID, the list is not there!! And I am opening the correct Vendor, I have checked it many times.