![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
|
New to FM8 and still having a hard time with it. So a question: is there a way to step through a value list in a loop? I would like to be able to use FM8's ScriptMaker to do something like the following using FM8's native scripting, not AppleScript. All of the items on the value list and all of the output would be text values. repeat with anItem in aValueList doSomethingTo (anItem) end repeat |
#2
| |||
| |||
|
|
Max wrote: New to FM8 and still having a hard time with it. So a question: is there a way to step through a value list in a loop? I would like to be able to use FM8's ScriptMaker to do something like the following using FM8's native scripting, not AppleScript. All of the items on the value list and all of the output would be text values. repeat with anItem in aValueList doSomethingTo (anItem) end repeat Use the Loop script step -- something like this (not really understanding what you're trying to do): Set Field [gText, YourValueList] Set Variable [$x = 0] Set Variable [$y = valuecount(gText)] Loop New Record/Request Set Variable [$x = $x+1] Exit Loop If [$x > $y] Set Field [MyTextField, getvalue(gText, $x)] End Loop |
#3
| |||
| |||
|
|
New to FM8 and still having a hard time with it. So a question: is there a way to step through a value list in a loop? I would like to be able to use FM8's ScriptMaker to do something like the following using FM8's native scripting, not AppleScript. All of the items on the value list and all of the output would be text values. repeat with anItem in aValueList doSomethingTo (anItem) end repeat Thanks for any suggestions. Max |
#4
| |||
| |||
|
|
On Wed, 9 Nov 2005 23:19:59 -0600, Howard Schlossberg wrote (in article <11n5m7qp8tajfd5 (AT) corp (DOT) supernews.com>): Set Field [gText, YourValueList] Set Variable [$x = 0] Set Variable [$y = valuecount(gText)] Loop New Record/Request Set Variable [$x = $x+1] Exit Loop If [$x > $y] Set Field [MyTextField, getvalue(gText, $x)] End Loop Thanks, Howard and Michael. Now I have the loop set up, and I'm successfully stepping through the text items of the Value List. My objective is to automate a series of string searches, with the search criteria coming from the Value List. Unfortunately, I now realize that Perform Find seems only to accept text as criteria. For my script to work, I need it to accept variables. Yet when I type in a variable ($gg), it just looks for the literal string "$gg." So now I'm hunting for a way around this. Thanks again for help. Max |
#5
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |