• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Li'l Help with my if, then, else statement?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Li'l Help with my if, then, else statement?


  • Subject: Re: Li'l Help with my if, then, else statement?
  • From: Jolly Roger <email@hidden>
  • Date: Thu, 01 Mar 2001 17:00:46 -0600
  • Replyto: email@hidden

on 3/2/01 4:02 AM, T.J. Mahaffey (email@hidden) wrote:

> Can someone tell me why this isn't following the if, then statement
> properly?
>
> The setup works beautifully, but if the "Utilities" folder IS present, it
> still tries to make on and errors out due to there being a folder of the
> same name already.
>
> Guidance is very much appreciated.

(snip)

Hi TJ,

First, your script will be much easier to follow if you used paths like:

file "MacLab NetAssist Setup:Remote Control Setup:Network Assistant
Preferences"

instead of this:

file "Network Assistant Preferences" of folder "Remote Control Setup" of
disk "MacLab NetAssist Setup"

Another thing, since you are not specifying *where* the folder "Utilities"
is, I don't see how the Finder would ever locate it with the following
statement - unless you happen to have a disk mounted named "Utilities".

if folder "Utilities" exists then

Better to do it like so:

if folder ((startup disk as text) & "Utilities:") exists then beep

HTH

JR


References: 
 >Li'l Help with my if, then, else statement? (From: "T.J. Mahaffey" <email@hidden>)

  • Prev by Date: Re: Different processor speeds
  • Next by Date: RE: Li'l Help with my if, then, else statement?
  • Previous by thread: Li'l Help with my if, then, else statement?
  • Next by thread: Re: Li'l Help with my if, then, else statement?
  • Index(es):
    • Date
    • Thread