Object paths?
Troy Rollins
troy at rpsystems.net
Wed Jul 21 01:17:32 EDT 2004
On Jul 21, 2004, at 1:02 AM, Richard Gaskin wrote:
> But I had thought that one of the parts of this thread noted that the
> long ID will include the path to the stack containing the object.
> This is no problem for an internally used stack that never moves, but
> should the path to the stack change the script will no longer work.
Correct. That form is not directly usable.
>
> Perhaps better would be to find a more common and generalized solution
> for the problem at hand. What is the problem at hand?
Hmm. The problem is, that in certain project types, where the
defaultStack is not entirely usable, because there are various scripts
which can open stacks with no user interaction, through callbacks and
asynchronous events, the apparent best method is to use a more explicit
path to an object, to avoid "can't find..." errors. That can add up to
a lot of typing. I was somewhat surprised, that the interface has no
support to get the full path to an object into some form which is
easily inserted into a script. It seemed to me, that it could be a
context menu item.
Sometimes, even if the path does not have to be overly explicit, I
think this would be helpful.
e.g. button "myButton" of group "layer 1" of group "The big container
group"
I don't even find anything which displays the path at all to such an
object. I would have though that the property inspector would, but it
doesn't. While the interface and the language support "infinitely"
nested groups, unless you have an exceptional memory, and strong typing
skills (I have neither) you don't really want to do it.
--
Troy
RPSystems, Ltd.
http://www.rpsystems.net
More information about the use-livecode
mailing list