Help with expression for Action

Hi @Steve. Thank you for this. The steps for recreating the error are below. Apologies about the longer sync time. I am still trying to put things in place to minimise this. Struggling a little because I can’t filter out much of the data in the Product Master File and Operations Master Check tables

  1. Select ‘Administration’ from the bottom menu
  2. Select 'ESB Aministration > ESB Product Administration > Create ESB Product
  3. Enter a random Product Code
  4. Select a Supplier from the list
  5. Change Pole Type to 38kv
  6. Change Pole Code to 315
  7. Click Save (you should be directed to Fabrication Create Stage Form)
  8. Enter value for Moisture Content
  9. Change Recategorise / Reject to Yes
  10. Recategorise Type: Cutback
  11. Fabrication Reject Reason: Machine Damage
  12. Fabrication Affected Area: Head
  13. New Pole Type: 10kv
  14. New Pole Code: 263
    15: Click Save

The error should trigger now (although it appears to submit both records to the Product Master File and Operations Master Check Tables respectively but only the original product details and not the new.)

I will provide access to the App (As Co-Author) & 2 Google Sheets also. If anything else is required please let me know.

Thanks again.

1 Like

Hi @Steve. I have had to make some change in my app to help with syncing so the steps above have changed a little. The steps are now

  1. Select Fabrication Create
  2. Enter a random Product Code
  3. Select a Supplier from the list
  4. Select Species & then Customer
  5. Pole Type: 10kv
  6. Pole Code: 263
  7. Enter value for Moisture Content
  8. Change Recategorise / Reject to Yes
  9. Recategorise Type: Cutback
  10. Fabrication Reject Reason: Machine Damage
  11. Fabrication Affected Area: Head
  12. New Pole Type: 10kv
  13. New Pole Code: 219
    14: Click Save

Previously I had been creating the product in Product Master File and then creating an operational record for that product in the Operations Master Check which is what your suggestions at the beginning of the thread are based on. However I have changed it so everything is done in the Operations Master Check table and I made what I thought were the necessary changes to your suggestions above re GetOMCType, SetPMFType etc…

However I still appear to be getting a very similar error.

Thanks again.

In the action, GetOMCDescription, the Moisture Content column is set to the result of the expression. [_THISROW].[Moisture Content], which is setting the column to its own current value. Is that the intention?

@Steve I added that in because I was getting an error saying (something like) 'Action Failed: Moisture Content would be blank and required. I tried that expression to use the value of Moisture Content in the current record.

My overall intention now is if [New Pole Type] and [New Pole Code] are given a value in the Operations Master Check table that they will update [Pole Type] and [Pole Code] as part of that record submission.

Your original suggestions worked perfectly when updating those values in the Product Master File so I am hoping to implement the same behaviour in the Operations Master Check table now instead.

So the OMC submission updates the PMF?

@Steve In the event of [New Pole Type] and [New Pole Code] being given a value by the user I actually just need the values of [New Pole Type] and [New Pole Code] to update the values of [Pole Type] and [Pole code] in the Operations Master Check table when the form is submitted.

Why not just have the user enter the new values in Pole Type and Pole Code directly?

@Steve: For some reason I convinced myself that my logic was the best way to help the operators of the app capture the data as we needed. I have just run through it again in my head and your suggestion will work perfectly fine too :smile:

I guess I couldn’t see the forest for the trees. It has been a long couple of weeks.

Thanks again.

1 Like

I COMPLETELY understand. Complex app development is difficult. It helps to have others to bounce ideas off of.

1 Like

Thanks for that @Steve. Your help and advice on here for me is extremely valuable and really appreciated.

1 Like