Re: Looping over all buttons

2012-02-23 Thread Mark Smith
Thanks Ken... I suppose one of those would work but I'd have to think about it :) The goal was the construction of a parameter list for revExecuteSQL that would look something like: revExecuteSQL gConnectID, tCmd, "tvar1", "tvar2", "tvar3", "tvar4", "tvar5", "tvar6", "tvar7", "tvar8", "tvar9" Ac

Re: Looping over all buttons

2012-02-23 Thread Ken Corey
On 23/02/2012 18:31, Mark Smith wrote: What if you want to put fld fieldname into myvar as in the original that Bob suggested: "put fld myfield into tvar"& x Myfield holds the name of a field that is being copied to a temp variable that is incrementing inside a loop. I tried various things but

Re: Looping over all buttons

2012-02-23 Thread Mark Smith
Ken Ray wrote > > > repeat with x = 1 to 12 > put "Hello" into field ("MyField" & x) > end repeat > > What if you want to put fld fieldname into myvar as in the original that Bob suggested: "put fld myfield into tvar" & x Myfield holds the name of a field that is being copied to a temp var

Re: Looping over all buttons

2012-02-23 Thread Ken Ray
On Feb 22, 2012, at 11:51 AM, Bob Sneidar wrote: > I am constantly doing do! Don't you? I used to use "do" a lot more than I do now… for example, if you have 12 fields named "MyField1" through "MyField12", instead of using: repeat with x = 1 to 12 do "put" && quote & "Hello" & quote && "into

Re: Looping over all buttons

2012-02-22 Thread Bob Sneidar
I am constantly doing do! Don't you? Bob On Feb 22, 2012, at 9:41 AM, J. Landman Gay wrote: > On 2/22/12 11:12 AM, Bob Sneidar wrote: >> not for. >> >> repeat with x = 1 to the number of buttons of this card >> do "put the hilite of button x into button"& x >> -- a better way >> put the

Re: Looping over all buttons

2012-02-22 Thread J. Landman Gay
On 2/22/12 11:12 AM, Bob Sneidar wrote: not for. repeat with x = 1 to the number of buttons of this card do "put the hilite of button x into button"& x -- a better way put the short name of button x into ButtonHilitesA[x]["name"] put the hilite of button x into ButtonHilitesA[x]["st

Re: Looping over all buttons

2012-02-22 Thread Mark Schonewille
Hi Mark, That would be: repeat with x = 1 to the number of buttons of cd y put the hilite of btn x into myButtonArray[x] end repeat If you want to have the hilites as text, you might want to use a normal variable instead of an array: put the hilite of btn x & cr after myButtonList Make sur

Re: Looping over all buttons

2012-02-22 Thread Bob Sneidar
not for. repeat with x = 1 to the number of buttons of this card do "put the hilite of button x into button" & x -- a better way put the short name of button x into ButtonHilitesA[x]["name"] put the hilite of button x into ButtonHilitesA[x]["state"] end repeat Now you have a numbered arra

Re: Looping over all buttons

2012-02-22 Thread Marty Knapp
Hey Mark, Yes - I'd loop through and make a comma delimited list repeat with x=1 to the number of btns put the hilite of btn x & comma after myHiliteList end repeat Then if you need to you can save that and use it to set the hilites at a later time. Works for me. Marty K Hi, I have 38 but