• 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: Exit Repeat
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Exit Repeat


  • Subject: Re: Exit Repeat
  • From: "Stockly, Ed" <email@hidden>
  • Date: Fri, 02 Oct 2015 16:49:59 +0000
  • Thread-topic: Exit Repeat

I've been using a construct like this since OS7 


repeat with x from 1 to 100
 repeat 1 times

   if x then 
    exit repeat
   end if

  end repeat
 if z then exit repeat 
end repeat

Ed Stockly
LA Times 
 
 On 3 Oct 2015, at 12:23 am, Jon Rosen <email@hidden> wrote:

Am I incorrect about this? As far as I can tell, there is no way exit from an individual loop of a repeat block; you can only exit from the entire block. I found a workaround using nested repeat loops, which works, but it seems kludgy to me. Is there a more elegant way to do this?

— Jon 
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >Exit Repeat (From: Jon Rosen <email@hidden>)
 >Re: Exit Repeat (From: Alastair Leith <email@hidden>)

  • Prev by Date: Re: Exit Repeat
  • Next by Date: Scripting SAPGUI for Java
  • Previous by thread: Re: Exit Repeat
  • Next by thread: Re: Exit Repeat
  • Index(es):
    • Date
    • Thread