Justinmind-logo
 

How to set an image for each data list row?

Mario shared this problem 3 years ago
In Progress

I have a Data Master of Restaurants populated by image URLs (attribute photo), names, ids, and ratings.

When I create a Data List (without any FILTER condition assigned to) I can easily assign each image which is inside a row to a datalist input (On Load event + set value), and the result set is a table of images, each one where it is supposed to be.

But when I apply a FILTER condition, for example to restrict the result properly, showing only the desired instances, I cannot find a way to assign the photo input text to its related image (envelope icon). When I put current row into the first slot of SELECT queries, the result is that the first image is repeated on each row. I can't find a way to simulate the typical instruction "current_row.photo" of popular programming languages.


Any help is appreciated. Thank you in advance.

Comments (6)

photo
1

Hi Mario,

Instead of using an on page load set value event, input the photo itself into the data master. To do this, change the data master type to 'file upload' and then in the View/Edit records section of the data master, upload a photo file for each record. Now a photo will be associated with each specific row.

photo
1

Hello, this does not work. Could you please fix this ?

photo
1

It should be working - can you attach some screenshots of your Data Master, the View and Edit records tab, and how the Data Master looks when you simulate?

photo
1

Hello Danielle, the solution you suggest does not work...

photo
1

I also tried this, and also it does not work. When go to preview it shows Browse button.

photo
1

Hello,

You have to go into the Data Master itself to add the Image File: /b95562a6f6c02ffea52b9a5602476264

For example, Field 5 is a "File" type, when I go into the Data Master palette and right click on the Data Master I want to edit it will take me to this screen. From here you can click on the blank field and select the image file you are looking for and then it will show up in your Data List/Grid.

Thank you,

-Chloe

photo