General Intersect
Malte Brill
revolution at derbrill.de
Mon Aug 22 07:10:30 EDT 2005
Hi Roger,
as saied before you would do this with a repeat structure.
eg:
repeat with i=1 to the number of buttons
if the short name of btn i="targetButton" then next repeat
if intersect(btn "targetButton", btn i) then
--do stuff
end if
end repeat
However, if it is a time critical script and you have many buttons to
check, I suggest that you store the ID of all buttons you need to check
in a custom property and use repeat for each from there:
Assuming you have stored the IDs in a customProperty called
allButtonsToCheck, each ID on a seperate line:
repeat for each line theButtonToCheck in the allButtonsToCheck of this
card
if theButtonToCheck=the ID of button "targetButton" then next repeat
if intersect(button "targetButton", button ID theButtonToCheck) then
--do stuff
end if
end repeat
All the best,
Malte
---
ArcadeEngine - prepare to WOW your audience within minutes
http://www.runrev.com/section/revselect/arcadeengine
http://www.derbrill.com/arcadeengine/forum
More information about the use-livecode
mailing list