1

Is it possible to embed in Spreadsheets an image from a Google Photo (Google+ in GDrive) folder?

I have images in Google+ albums and with new functionality show them in Google Drive in location: My Drive/Google Photo .... I tried to show these images in Spreadsheets with:

=image("https://googledrive.com/host/FOLDERID/NAMEPHOTO.jpg")  

but see nothing, no image, no errors just a blank cell.

What should I do?

In the major I want to organize (moving, upload etc.) and edit (rename) images in album on Google+ with function and google scripts for spreadsheet. So I try use new functionality - Google Photo Albums see in GDrive - to do this. And finally i need to show the images from albums Google+ (folder Google Photo in GDrive) in Spreadsheet Cells.

Rubén
  • 34,714
  • 9
  • 70
  • 166
Geery.S
  • 121
  • 2
  • 10

1 Answers1

3

Google Drive hosting (googledrive.com/host/FOLDERID/...) is being deprecated. To properly embed an image on Google Drive, you need to follow the following steps:

  1. In Google Drive, right click on an image and select either "Share..." or "Get Link"
  2. You will get a link that looks either like:
    • drive.google.com/file/d/RaD0mNum3er/view?usp=sharing , or
    • drive.google.com/open?id=RaD0mNum3er
  3. You need to convert the link to something like:
    • drive.google.com/uc?export=download&id=RaD0mNum3er
  4. In your cell, enter =image("drive.google.com/uc?export=download&id=RaD0mNum3er")

To quicken the process, I'd create 3 new columns (let's say C, D, E).

  • C2 = drive.google.com/open?id=RaD0mNum3er
  • D2 = =REGEXEXTRACT(C2,"(?:(?:file/d/)|(?:open\?id=))(\w+)")
  • E2 = ="https://drive.google.com/uc?export=download&id="&E2

where

  • C is the link you got from Google Drive
  • D is the extracted file ID, and
  • E is the converted the permalink
daniel
  • 638
  • 4
  • 14