When raising a non-conformance for operations I need to automate population of the operation field with the first operation for the matching assembly in the job. Could someone please assist me with the custom code to do this
You can do this with widgets.
Hi Aaron, I have tried a number of ways.
Can you explain how in more detail please.
Are you still in E9?
No, we are E10
![]()
Unfortunately, I will not be able to assist you any further as I do not have that module.
The steps for any BPM (automation) is to mimic what is occurring when the user interacts with the screen.
When events are made in the screen, it send data back and forth to the server. Trace Logging shows what actually is sent back and forth.
The trace will have a Business Object and a Method called. Often you can default data when the record is being created, or the first time the record is being opened.
I would offer that this may be more than you want to take on alone though unless you have gone through some form of training.
Hi Jason,
Thanks for your response, I am ok with calling the methods and using the trace log – the issue is that I need to use custom code to look for only the first operation of the linked job & assembly, the method returns a list of all possible operations.
Thanks
Tracy
It will likely require code. Without knowing what your current logic looks like, I can only offer theory, but the basic idea would be a Set Field widget with something like:
Db.JobOper.Where(J => J.Company == nonConfRow.Company && J.JobNum == nonConfRow.JobNum && J.AssemblySeq == 0).Select(J => J.OprSeq).DefaultIfEmpty(0).Min();