open me <> open stack "xxx"?

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
rozek
Posts: 151
Joined: Mon Jun 19, 2006 2:29 pm
Contact:

open me <> open stack "xxx"?

Post by rozek » Fri Jun 20, 2008 12:58 pm

Hello again!

RR is driving me crazy...

Within a stack script handler of a library stack (which has already been registered by "start using"), I tried to open the stack's window using

Code: Select all

open me
because "me" contains a reference to the stack.

Unfortunately, this approach doesn't work. Me contains the correct reference, but it does not work...

If I use the command

Code: Select all

open stack "xxx"
where xxx is the stack's name, everything works fine.

What am I doing wrong?

Do I really have to write

Code: Select all

open stack (the short name of me)
to achieve the desired effect?

In that case: how do I find out when to write a reference itself or "the long|short name|id of" that reference? To me it seems, that I always use the wrong expression(s)...

Thanks in advance for any help![/quote]
Kind regards,

Andreas Rozek

rozek
Posts: 151
Joined: Mon Jun 19, 2006 2:29 pm
Contact:

Post by rozek » Fri Jun 20, 2008 1:13 pm

Ok, I got it!

The command "open" seems to require a "long name" rather than a normal object reference. This means:

- after "start using" a stack you may refer to it and its contents using normal references, but
- you can't open it with such a reference

Only "open (the long name of me)" works as foreseen.

Programming has never been so easy, yeah!!!
Kind regards,

Andreas Rozek

Post Reply