This tip below reminds me of that phrase years ago by Ed or Ted or somebody else that said "program to the interface, not the implementation."
Alan's example was very good and not cluttered.
On 2016-07-06 09:50, rafael copquin wrote:
I would do it this way:
On your first form, put a button to call the second form. In the button's click event do this:
do form secondform with thisform
On the second form init event:
lparameters toForm
thisform.oForm = toForm (you created a property called oForm in the second form and attach the parameter to it)
the second form should be modal. Then you make whatever changes you need.
When you completed your changes, I assume you typed something in a textbox (named txtWhatIType in this example)
thisform.oForm.text1.value = thisform.txtWhatIType.value thisform.oForm.text1.refresh
release thisform
What you have done here is send a reference to the first form to the second form (thisform). It gets into the second from in its init event and is captured in the second form oForm property
When you finish your changes, you pass the value of those changes from the txtWhatIType textbox into text1 (or whatever you named it) in form
- Just in case, but perhaps not necessary, you refresh the first
form's text1.value
You release the second form and you should have the value you want in the first form
Rafael Copquin
[excessive quoting removed by server]