Path: utzoo!attcan!uunet!husc6!ukma!psuvm.bitnet!rice.bitnet!pgreenea From: PGREENEA@RICE.BITNET Newsgroups: comp.sys.mac.hypercard Subject: Re: efficient cardExists function Message-ID: <346PGREENEA@RICE> Date: 16 Jun 88 17:39:35 GMT References: <5888@bunny.UUCP> Organization: Rice University - ICSA Lines: 30 In article 5888@bunny.uucp, jwg1@bunny.uucp (Jim Gish) says... >I need a function CardExists ( cardName ) that will return true iff >a card of name cardName exists in the stack. One way, perhaps not the best, is -------------------------------- push card go to card cardName if the result is empty then put true into itExists else put false into itExists end if pop card -------------------------------- If the card isn't there, the result will contain either "Can't find card cardName" or "No such card"; I think it depends on the version of HyperCard (the first message for 1.0.1, the second for 1.1 and 1.2). Pam Greene Rice University PGREENEA@ICSA.RICE.EDU Neither ICSA nor Rice (nor anyone else, for that matter) necessarily agrees with me. I'm just a student, after all; what do I know?