[Solved] Displaying images like ads in app from spreadsheet

How can I retrieve images from spreadsheet and display them one after the other in my app?.
currently it displays properly,using the when screen open component,and blocking it to get specific images uploaded to the app files.
but i would love to get images from Airtable spreadsheet @tatiang @muneer

1 Like

Please don’t tag people, if they can answer they will. :slight_smile:
As for your question, you can connect your airtable as a data source within your app. From there you can loop through each row and display it either through a data viewer or an image placeholder depending on your usecase.

3 Likes

What is available in the Airtable sheet? The URL of the image or the image itself?

If the URL is saved in the sheet then you need to loop through the table to display the images by assigning the URL from the table to the Picture property of the image component.

You may need to place this inside a timer to change the images every so and then.

2 Likes

The images itself is what I have in the spreadsheet

1 Like

Noted, thanks

In Airtable, all attachment fields have extra JSON sets which include a private URL for both a thumbnail and a full image which you can use to view the images.

[Update]
The URL generated by Airtable would be looking like this

https://dl.airtable.com/.attachments/1f3d5b146299eff18cc0d43c6827fdb9/e837f5a5/The10Factorsoflive.xlsx
1 Like

So how do I block this

1 Like

Use the get row block to see the added JSON information in the Attachment field.

1 Like

If you have added the image directly to the Airtable column, Airtable will automatically add your image to the Attachment column of your table and will provide the generated URL of your image in the column.

This way you can get the image URL using the get value block or any other Data Sources or Data Viewer List blocks

1 Like

I do add the images but no URL was generated

1 Like

I wouldn’t be able to give more comments without seeing the actual table. If you can share your Airtable table or Airtable base then I can see the actual table setup and provides advice of how to go about it.

You can send me the share link in DM if you do not want to share it here.

1 Like

Ok…I will share that with you now

1 Like

Check your DM

1 Like

You sent me an invitation link where I have to supply email and password. Please send a share link instead.

See this small demo
Airtable-Ads

This is the blocks that goes with it

Hope this solves your issue.

1 Like

fvck, @muneer you are such a genius
thanks this was just the way i want it,of course i will make some adjustments

You can now safely remove the share from your Airtable table/base.

Have Fun Thunking!

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.