Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
An issue has been identified on Qlik Cloud hub, please visit our Status Update Page for details: GET THE LATEST
cancel
Showing results for 
Search instead for 
Did you mean: 
Fanch
Partner - Creator
Partner - Creator

Load a variable from a a field

Hi everybody,

I want to initialize a variable from a field.

I use a script like this :

Capture.JPG

So, i just want to replace the value 5 by the value MaxNumberCommat.

I've tried Let Vi=Max(Comptelesvirgules) just before For i = 1 to 5, but it does not work 🙄

Thanks in advance for your help 

 

 

 

1 Solution

Accepted Solutions
sunny_talwar

Try this after MaxNumberCommat table

LET vMaxNumberCommat = Peek('MaxNumberCommat');

FOR i =1 to $(vMaxNumberCommat)

View solution in original post

3 Replies
sunny_talwar

Try this after MaxNumberCommat table

LET vMaxNumberCommat = Peek('MaxNumberCommat');

FOR i =1 to $(vMaxNumberCommat)
mfarsln
Creator II
Creator II

Hi,

You should use variable to take max value.

After getting max value in table, you should create a variable to carry its value. Then you can use this variable on your for loop.

 

let vMax = peek('MaxNumberCommat');

for i=1 to $(vMax)
.
.

 

 

oops..Sunny is faster than me 🙂

Fanch
Partner - Creator
Partner - Creator
Author

Too strong !!! 

Thanks a lot 🍺