I want to take a field (name or id) as a parameter, and then write into that field. Currently the code looks like this:
Code: Select all
command writeOutput pField
put "Hello" after pField
with the call being something like:
Code: Select all
put the long id of fld "test" into tTest
writeOutput tTest
However, this just updates the pField variable to have the long id of fld "test" followed by "Hello".
I've instead tried using the "do" command:
Code: Select all
command writeOutput pField
do "put ""e&"Hello""e&" after "&pField
which works, but seems ugly. Is there a better way to do this?