Apostasy seems a little strong, Gene... :-) According to the help file, "Whenever possible, use EVALUATE( ) or a name expression to replace macro substitution using the & Command. EVALUATE and name expressions execute faster than macro substitution."
Macro expansion is incredibly useful, of course, and used to be the only way to accomplish a lot of things of this ilk. Name expressions and EVALUATE() came along and obviated the need to use macro expansion for many of those things but not all of them. If you have some kind of loop with a macro inside of it, the EVAL or name epxression can be significantly faster over the lifetime of the loop. -- rk -----Original Message----- From: ProfoxTech [mailto:[email protected]] On Behalf Of Gene Wirchenko Sent: Wednesday, August 13, 2014 7:53 PM To: [email protected] Subject: Re: Proper way to reference a control > > thisform.txt ? .value = myobj. ? > thisform.txt ? .refresh() > >and I can't seem to get it right. > >Any ideas? For this sort of playing around with text to create source, I tend to use & which is usually apostasy or something around here. It is amusing that I am posting about another approach after all of the & suggestions. You could use evaluate(): what="imf" theobj=evaluate("thisform.txt"+what) theobj.value=evaluate("myobj."+what) theobj.refresh() If you want the proper way, I suppose you could use proper(). <BEG> Sincerely, Gene Wirchenko _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/DF1EEF11E586A64FB54A97F22A8BD04423C36D4248@ACKBWDDQH1.artfact.local ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

