Q:

View data in Google Spreadsheet, where data comes outside

I'm developing a web application that handles some kind of query engines. It means my application generates a result of a query, and its user can view it on the web application.
What I'd like to do is to help the user open the result in Google Spreadsheet. For instance, when a user is viewing the result on the web app and clicks the button named "Open this data in Google Spreadsheet", the data is shown in Spreadsheet.

Is it possible to develop such a feature in a web application?
Where can I get the information to develop it?

Any suggestions would be welcomed!

A:

What you need to do in the code that is triggered by "Open this data in Google Spreadsheet" is to actually create the document IN Google Spreadsheet and then redirect the user to the document you just created.
You need do a couple of things.

Get authorization from the user to actually access his Google Spreadsheet account.
Create the document.
Redirect the user to it.

Documentation for [1] can be found at https://developers.google.com/sheets/guides/authorizing. Documentation for [2] and [3] can be found at https://developers.google.com/sheets/quickstart/dotnet (for C#, other languages are available)

