I insert an image in Google Sheets as a blob rather than link it with a URL - google-sheets-api

I want to insert a blob object (.jpg image) with Google Sheets API.
Does Google Sheets API allow for blobs inside the spreadsheet's cells?
I know that inserting the image directly into the spreadsheet by hand without using API is possible.

In the current stage, unfortunately, the image blob cannot be directly put into Google Spreadsheet using Sheets API. So, it is required to use the workarounds. In this answer, I would like to propose the 2 workarounds for achieving your goal.
Pattern 1:
In this pattern, IMAGE of the built-in function of Google Spreadsheet is used. The flow is as follows.
Upload the image to Google Drive using Drive API.
Share publicly the uploaded image using Drive API and receive the URL of the image.
Put a function of =IMAGE("URL") to a cell using Sheets API.
By this flow, your goal is achieved. If you can know the direct link of the image, you can directly use only the 3rd flow of the above flow.
Pattern 2:
In this pattern, the image is inserted into the Spreadsheet using Web Apps created by Google Apps Script.
Upload the image to Google Drive using Web Apps.
Put the image blob into the Spreadsheet using Web Apps.
By this flow, your goal is achieved.
References:
IMAGE
Web Apps

Related

How do I connect Google Sheets as a database to a Kotlin app?

What I plan to achieve is be able to pull data from the sheets.
Name
I.D
Image URL
Website URL
and populate a text view, image view and webview.
The endpoint mentioned http://spreadsheets.google.com/feeds/<feed>/<key>/<worksheet>/public/<...>?alt=json was provided by an older Google API called GData (Google Data Protocol).
That API however is being deprecated. Users of GData API (Spreadsheet endpoint) must migrate to Sheets API.
To fetch the values of the Sheets file from your Kotlin app, I’d recommend using the method spreadsheets.values/get.

How do I Automate BIng Maps data upload?

How do I upload data to Bing Maps without having to use the portal? I can’t find anything in the documentation that mentions this, but any time we update our data, I have to manually upload a new XML file. Ideally, we would automate the upload whenever we update the data.
The closest I can get is the Uploading Data page, but there's nothing there about it.
Use the data source management API: https://learn.microsoft.com/en-us/bingmaps/spatial-data-services/data-source-management-api/
If you are working in .NET, you might also find this library useful: https://github.com/Microsoft/BingMapsSDSToolkit

Sheets API V4 Spreadsheet View Properties

I'm trying to zoom into a google Spreadsheet using an API call. Is this possible? I would also like to enable full screen from another API call once I dynamically create a spreadsheet, but I can't find it in the documentation, anyone knows how to do this?
Currently, the functionality that lets you Zoom in and out the spreadsheets is not supported in Base Script Services (Class Ui). Also, you have a similar SO post, have a check.

How to View a Google Spreadsheet Doc as a PDF

I would like to know if it's possible to view a Google Spreadsheet Doc as a PDF without first manually converting it as a PDF? I don't want to share a link directly to the spreadsheet, I want to share a link to a PDF version of it which ends up looking better (in Print View rather than Spreadsheet Document View)
I know I can Print > Save as PDF, then download to local machine, then upload and save somewhere on my server. But is there is a way to be able to view the spreadsheet as a PDF.
I have Google'd this and found nothing. The best I could come up with is the Google Document Viewer (https://docs.google.com/viewer) but that does not seem to give mt the option I am looking for. Further, I do not want to install any Chrome plugins, etc. because I want to be able to share a link to the PDF with people but not have to have them install a plugin to see the doc.
Unfortunately, what you are trying to do and the way you are trying to do it is not a capability within Google Docs. Sorry.
I think the best way is to use Google Drive API to write own script that will do this job. I mean:
You have a web server
Write a simple method in any web technology, such as PHP, Python, Java, C#, whatever you like and your server is able to serve. This method is connected to the google drive through it's API to your account, knows which spreadsheet to take care of and how to understand the columns. This spread should be parsed to HTML and with some popular tool (proper for your programming language or server's operating system) you create the PDF. The method should create HTTP response with header type: application/pdf.
You provide interested people with the link under which your method is available.
I guess this reference should help you to use Google API:
How to download the resources:
https://developers.google.com/drive/web/manage-downloads
How to convert (i.e. to PDF) and open the resources in your own application:
https://developers.google.com/drive/web/integrate-open#open_and_convert_google_docs_in_your_app
I hope this helps.

Is there any quick and easy way to upload a Google Doc from SAP?

We're creating a custom table in SAP comprising all of the information we need and the customer needs the report from this table uploaded to Google Docs. We do not use Business By Design. Is there any other quicka nd easy way to upload our report?
I don't know much about SAP but the Documents List API has methods to programmatically upload a document to Google Docs: https://developers.google.com/google-apps/documents-list/.
For instance, if you can export the SAP table as a csv file, that can be automatically converted into a Google Spreadsheet during the upload process.
You could also go with a no-programming required solution and install the Google Drive app on a machine with access to the files for automatic sync up to Google Drive:
http://support.google.com/drive/bin/answer.py?hl=en&answer=2374989
suggest you take a look at the SAP Developer Network (SDN) / SAP Community Network (SCN) where there is a project called ABAP2GAPPS that has done this.
Note the ABAP2GAPPS example is a bit difficult to figure out (but you can learn a lot from it), and it also uses the OAuth2 'authorization code flow" OAuth2.0 flow/pattern, which requires an end-user 'consent' in an browser pop-up...so if you want to push up a file from ABAP automatically from a background job without end-user interaction then ABAP2GAPPS is not the full answer (but again, ABAP2GAPPS is a great example, suggest you look at it.)
We recently were able to achieve an interface from SAP ABAP to the Google Fusion Table API using OAuth2, with only about a 100 lines of ABAP...and the techniques we employed could be used on any of the Google API's...here's a link to the video:
Link to YouTube video interface ABAP to Google API
hope you find this helpful