Re: Getting a list of groups on a card
This should work: *function* allGroupNames X *-- returns all groups for id X* *repeat* with i = 1 to the number of groups of X *put* the short name of of *group* i of X cr after R *end* *repeat* *return* R *end* allGroupNames ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Getting a list of groups on a card
I put this in a button and it seemed to do pretty well. Is there any reason to NOT do this with try/catch and toss the error? *on mouseUp* * put 1 into i* * repeat until tDone* * wait 100 milliseconds with messages* * try * * put the long id of group i return after tGroups* * add 1 to i* * catch tErr* *-- ignore tErr* * put true into tDone* * end try* * end repeat* * put tGroups* *end mouseUp* On Sat, Feb 26, 2011 at 12:33 PM, J. Landman Gay jac...@hyperactivesw.comwrote: On 2/25/11 8:50 PM, Peter Haworth wrote: The groupnames and groupids properties of a card only report the top level groups. Other than iterating through all the controls on a card, is there a way to get a list of the gorup names and/or IDs that are in the top level groups? I don't think so. The closest I could get was: put the number of groups of group 1 That gives a number, and you could iterate through those to get names. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: Getting a list of groups on a card
That's basically what I'm doing, just checking there wasn't some other property or perhaps a syntax like the groupNames of group xyz, but seems not. Pete Haworth On Feb 26, 2011, at 12:11 PM, Mike Bonner wrote: I put this in a button and it seemed to do pretty well. Is there any reason to NOT do this with try/catch and toss the error? *on mouseUp* * put 1 into i* * repeat until tDone* * wait 100 milliseconds with messages* * try * * put the long id of group i return after tGroups* * add 1 to i* * catch tErr* *-- ignore tErr* * put true into tDone* * end try* * end repeat* * put tGroups* *end mouseUp* On Sat, Feb 26, 2011 at 12:33 PM, J. Landman Gay jac...@hyperactivesw.comwrote: On 2/25/11 8:50 PM, Peter Haworth wrote: The groupnames and groupids properties of a card only report the top level groups. Other than iterating through all the controls on a card, is there a way to get a list of the gorup names and/or IDs that are in the top level groups? I don't think so. The closest I could get was: put the number of groups of group 1 That gives a number, and you could iterate through those to get names. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Getting a list of groups on a card
The groupnames and groupids properties of a card only report the top level groups. Other than iterating through all the controls on a card, is there a way to get a list of the gorup names and/or IDs that are in the top level groups? Pete Haworth http://www.mollysrevenge.com http://www.sonicbids.com/MollysRevenge http://www.myspace.com/mollysrevengeband ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode