Set field value to field in a different form

Set field value to field in a different form

FormA contains a string field (Line1). FormB contains a lookup to FormA (Choose FormA) and a string field (Line2). On success of FormB, I want to use FormB's Line2 as the value of FormA's Line1

For example:

FormA's Line1 is null
FormB's Line2 is "apple"
When I hit FormB's submit, FormA's Line1 is now "apple"


I have tried


(On Success)


  1. FormA.Line1 = input.Line2
which gives me  Only SubForm related fields can be updated


and


  1. FormA[ID == input.Choose_FormA].Line1 = input.Line2
which gives me  Improper Statement  Error might be due to missing ';' at end of the line or incomplete expression

Please advise