On Sat, Aug 4, 2012 at 2:58 PM, J. Landman Gay <[email protected]> wrote: > If you substitute "field x of card y" for every instance of "the long name > of the target" in your script, you'll probably see the problem right away. > As Alex mentioned, the "put" line evaluates to: > > put 45 into fld (field x of card y)
The catch is that the handler has no advance knowledge of what field or card it can be called from--I'm trying to make something generic that can add a currency formatted value to a field that already contains a currency formatted value. In several places, the names of the fields are actually being constructed by string manipulation (e.g., val_sbt comes from [ fldNam & "_sbt" ], and then I want to add the $123.45 in val (or possibly fld fal) to the $852.87 already in fld_sbt.) And then, when I"m done on the page, I have to add fld_sbt to a totalling field on yet another page. So the solution *seems* to be to send a message to the field to add something to itself. But the handler only knows the name by "the target", and it seems to take several lines of code to parse a long name into a card X and Field Y. My real need is the very narrow issue of a handler pulling the value of the field that called it, and then putting something back in. It seems that this should take one line of code, not 8 or 10. Thanks hawk -- The Hawkins Law Firm Richard E. Hawkins, Esq. (702) 508-8462 [email protected] 3025 S. Maryland Parkway Suite A Las Vegas, NV 89109 _______________________________________________ use-livecode mailing list [email protected] Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
