DanBrill Posted July 9, 2006 Posted July 9, 2006 Hi, Just getting into FM 8. Some really nice changes. I love variables, but I'm confused on one point and the documentation is of no help. In the SetVariable dialog box there is a field for repetition. Does this mean the variable can be repeating? If so, this really makes it a very useful thing in that you can create arrays. But I can't seem to make it work this way... Or does this refer to the repetion number of a field that you are using to set the value of the variable? If this is the case it seems like this could be accomplished with the getRepetition() function, and is a lot less useful. Any clarity anyone can provide will be most appriciated. Thanks, Dan
comment Posted July 9, 2006 Posted July 9, 2006 This is explained in the help, under Set Variable script step: "Repetition is the repetition (index) number of the variable you want to create."
DanBrill Posted July 9, 2006 Author Posted July 9, 2006 Thanks. That's what it seemed to be indicating. I guess I'm doing something wrong then. For example if I create a script: Set Variable [$$RepeatingVar ; Value: "A"] Set Variable [$$RepeatingVar [2] ; Value: "B"] Show Custom Dialog[ GetRepetition($$RepeatingVar;1) & ", " & GetRepetition($$RepeatingVar;2) ] The dialog box returns A, A. Why isn't it returning A, B? Thanks, Dan
comment Posted July 9, 2006 Posted July 9, 2006 GetRepetition() expects a repeating FIELD as the first argument - so I am surprised it returns anything with a variable. However, this syntax works: $$RepeatingVar[2]
DanBrill Posted July 9, 2006 Author Posted July 9, 2006 Thanks. That's what the documentation never gets around to -- how to access the data. Dan
comment Posted July 9, 2006 Posted July 9, 2006 Yes. But I am afraid you won't find repeating variables very useful. They do not behave like repeating fields. For example, there doesn't seem to be a way to add, or multiply, 2 repeating variables in a single step.
Recommended Posts
This topic is 6773 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now