## Problem

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller

Posts: 12
Joined: Tue Nov 15, 2016 12:17 pm

### Problem

When I am trying to execute the code an error appears stating:

(Repeat: error in 'with' end condition expression)

I am unsure of what this means, could someone help?

shaosean
Posts: 906
Joined: Thu Nov 04, 2010 7:53 am

### Re: Problem

Can you post your code that is causing the error?

Klaus
Posts: 10755
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

### Re: Problem

Hi Michael,

1. welcome to the forum!
2. What Sean said, guessing is just too timeconsuming!
3. Will move this thread to the "Beginners" forum.

Best

Klaus

MaxV
Posts: 1565
Joined: Tue May 28, 2013 2:20 pm
Location: Italy
Contact:

### Re: Problem

Repeat with example:

########CODE#######
repeat with i=1 to 10
end repeat
#####END OF CODE#####

Livecode Wiki: http://livecode.wikia.com
My blog: http://livecodeitalia.blogspot.it
To post code use this: http://tinyurl.com/ogp6d5w

shaosean
Posts: 906
Joined: Thu Nov 04, 2010 7:53 am

### Re: Problem

Hi, thanks for the code sample.. That should work without an issue, so not too certain why the LiveCode engine is complaining.. What version are you using and what operating system?

Klaus
Posts: 10755
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

### Re: Problem

???

SparkOut
Posts: 1870
Joined: Sun Sep 23, 2007 4:58 pm

### Re: Problem

Typical new user mistake:

Code: Select all

``repeat with each line tLine of tList -- will not work``
Use

Code: Select all

``repeat for each line tLine of tList``
or use the "with" syntax Max shows above

If you don't need to have the specific numerical indexin the "with" syntax then repeat for each is much, much faster in the loop.

MaxV
Posts: 1565
Joined: Tue May 28, 2013 2:20 pm
Location: Italy
Contact:

### Re: Problem

Klaus wrote:???

I just furnished a repeat example.
Livecode Wiki: http://livecode.wikia.com
My blog: http://livecodeitalia.blogspot.it
To post code use this: http://tinyurl.com/ogp6d5w

Klaus
Posts: 10755
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

### Re: Problem

I know, tell it Sean!

shaosean
Posts: 906
Joined: Thu Nov 04, 2010 7:53 am

### Re: Problem

i don't really pay that much attention

dunbarx
VIP Livecode Opensource Backer
Posts: 5824
Joined: Wed May 06, 2009 2:28 pm
Location: New York, NY

### Re: Problem

Hmmm.

Never saw this error before. If one does this, as per SparkOut's suggestion:

Code: Select all

``````on mouseUp
repeat with each word tWord in "aa bb cc" --note "with", not "for"
put tword
end repeat
end mouseUp``````
You get
compilation error at line 2 (repeat: expecting '=') near "word", char 16
and not
error in 'with' end condition expression)
But why speculate? Hey Michaellad, where are you?

Craig