Smart Editor Widget - Related Table Editing - Scope Issue

392
0
11-06-2018 01:54 PM
TheKenerson
Occasional Contributor

Hi,

      I'm working with the smart editor widget and I have a scope issue when editing a related table. 

      

        Specifically, I am working with the attribute change event, and my coding challenge is as follows:

       I want to change value of a field in my main table when the value of a particular field is modified in the related table. I haven't been able to find a good way to do it. When I attempt to read or change the value of a field in the main table, when changing the attribute in the related table, it is undefined. It appears to me that the main table field is simply not in scope at that moment.

       The best workaround I have found is to create a global bool variable. Set the value  to true when the related table is being edited, and then review the bool variable when the user click save on the main form, which will then make the attribute change on the main form. That's real clunky though. Its got holes.

          Any suggestions?

0 Kudos
0 Replies