Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Creating a dynamic URL with Fields values

Hi, I am new to QlikView and am trying to find a method of displaying an image within a text object based on a URL which is dynamically constructed using field values. For example I have tried to create an expression using a field 'Serial_number'. If I construct the url as a straight string with values it display ok but a soon as I try to replace the values with the field values it does not.

 

 

='http://mysite.myimages.co.uk/imagestore/Titles/0' +

left(chr(Serial_number),3) + '00/0' + chr(Serial_number

) + '-FC8.JPG'

Any help would be much appreciated.

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Have you tested the outcome of the string e.g. in a text box?

I just noted that you are using chr(SerialNumber), probably to convert a number to a string.

You don't need this (and I believe it will not return what you want), try removing the chr()

View solution in original post

4 Replies
swuehl
MVP
MVP

The string concatenation operator in QV is &, not +, so try this:

='http://mysite.myimages.co.uk/imagestore/Titles/0' & left(chr(Serial_number),3) & '00/0' & chr(Serial_number) & '-FC8.JPG'

Not applicable
Author

Still not working with the ampersand I'm afraid. It does work with the following

 

http://mysite.myimages.co.uk/imagestore/Titles/032400/032496-FC8.JPG but not with the above.

swuehl
MVP
MVP

Have you tested the outcome of the string e.g. in a text box?

I just noted that you are using chr(SerialNumber), probably to convert a number to a string.

You don't need this (and I believe it will not return what you want), try removing the chr()

Not applicable
Author

Now works by removing the CHR.  Many thanks.