The little object that wasn't there

Peter Haworth pete at lcsql.com
Fri Apr 5 18:06:12 EDT 2013


Some time ago, I experienced some unreliability when using "there is a" in
conjunction with a control reference, never did figure out why.  Now I
always use "exists" when checking for Livecode objects and "there is a" for
checking for files, folder.

Pete
lcSQL Software <http://www.lcsql.com>


On Fri, Apr 5, 2013 at 12:03 AM, Scott Morrow
<scott at elementarysoftware.com>wrote:

> What about
>
> if there is a button "myButton" then
>      or
> if exists(button "myButton" of cd "myCard" of stack "myStack")
>
> --
> Scott Morrow
> Elementary Software
> (Now with 20% less chalk dust!)
> web       http://elementarysoftware.com/
> email     scott at elementarysoftware.com
> office     1-800-615-0867
> ------------------------------------------------------
>
>
>
>
>
>
>
> On Apr 4, 2013, at 11:25 PM, "Cal Horner" <calhorner at xtra.co.nz> wrote:
>
> > I have a stack (like everyone else) and the 'Master' card contains all
> the
> > objects needed to make a complete window.
> >
> > Some of the buttons are needed for separate cards, but not all of the
> cards.
> > When I need one I do the standard thing, push -> go to master card ->
> copy
> > one of the buttons -> pop -> paste. Works a treat.
> >
> > Here's my problem:
> >
> > How do I, programatically, check to see if the button exists, before I do
> > the standard thing?
> >
> > And how do I check for an existing button - programatically - before I
> > delete a button that isn't there?
> >
> > Surely there must be a command that handles that.
> >
> > Cal
> > _______________________________________________
> > use-livecode mailing list
> > use-livecode at 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 at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



More information about the use-livecode mailing list