Integrated Application Platform › Forums › General › ExpandControl Refresh › Re: Re: ExpandControl Refresh
.Send “sends” a message to parent Controller’s. (Only a Controller can respond to Send.)
You are probably more used to receiving these messages. For example, when you define an On_… method to respond to a button. The button is doing .Send(“On_…”)
If a parent Controller has a method with the same name as the first argument to Send (in this case “GetRecordControl”) then that method will be called with the remaining arguments to the Send (in this case there are no additional arguments).
If no method is found, then .Send returns 0.
In this case, the parent Controller with a GetRecordControl method is the RecordControl. It responds by returning itself.
Once we have the parent RecordControl, then we add “observers” to it. The method passed to AddSetObserver will be called by RecordControl whenever its Set method is called. The method passed to AddObserver will be added as an observer to the Record managed by the RecordControl. Record observers are called whenever a field is changed in the record.
I’m not sure why you can’t inspect rc, maybe because it has recursive self references.
Does that help?