Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

What does it means "must not cross a line boundary"?

Hi All,

I am reading about the reference manual and came across this statement:

Since the for..next statement is a control statement and as such is ended with either a semicolon or end-ofline,

each of its three possible clauses (for..to..step, exit for and next) must not cross a line boundary.

What does it mean?  Can anyone explain or provide a simple example ? 

I tried to search online but to no valid.

Thanks

Chun Wey

1 Solution

Accepted Solutions
Colin-Albert

You must type the "for..to..step" expression on one line of your script. You cannot put a line break between for, to or step.

For I = 1 to 10 step 2     is OK

For I = 1 to 10

Step 2.                         Will error

View solution in original post

3 Replies
Colin-Albert

You must type the "for..to..step" expression on one line of your script. You cannot put a line break between for, to or step.

For I = 1 to 10 step 2     is OK

For I = 1 to 10

Step 2.                         Will error

Not applicable
Author

Thanks Colin for the clear example. 

Rdgs,

Chun Wey

Not applicable
Author

Another example to show what this mean:

Set vLot =1;

1. ERROR:

if vLot =1 then  vLot= vLot +1 end if;

2. OK:

if vLot =1 then;  vLot= vLot +1; end if;

3. OK too:

if vLot =1 then

  vLot= vLot +1

end if;


This illustration can be found in QLikview reference manual SR 9 page 246 on if then elseif else end if control statement.