Google Sheets API - android

Good Morning
I am in the process of developing an Android application for a client, that stores his data in a Google Drive Spreadsheet.
My question is, for pulling the data from the spreadsheet to the Android application, would I need to use the Google Sheets API. I will be pulling certain column data to populate text box controls and passing them back to the spreadsheet.
What would be the most efficient way to do this and id there any tutorials that anyone can point me to, so I can get a feel for accomplishing such a task.
A couple of other things I thought of, if at all possible was storing the data in the local data storage and passing that data to the spreadsheet if that is possible.
Any help or information would be helpful.

A few options to consider:
You can publish the sheet to the web and pull the feed dynamically (https://developers.google.com/gdata/samples/spreadsheet_sample)
You can access the sheet programmatically (without an OAuth callback) if you register your app and generate client credentials in your Google console (https://developers.google.com/accounts/docs/OAuth2#serviceaccount)

Related

What are the limitations of syncing data to Google Account?

Is there any downsides to using Google Account? Is there any limit?
Why ask this? It's because I played some android games for research and found out many of them don't save the user data just warning the users removing the games will remove whole data as well.
Ironically, all of them provided world rankings using Google Accounts.
So, I became curious and wanted to get some opinions of experienced people if there is no problem for beginners like me to use Google Account for backing up data.
The data is going to be created with SQLite so I cannot let users save in their own SDCards. If Google Account is not good for saving data, I need to get an FTP server instead. (I'm not sure if I can deal with it well, though.)
But I really wanted to use Google Account, so was just about to start to study it.
Can I just use Google Account for user data? or better to get my own FTP server?
There is something that Google offers which is known as the Android Backup Service. It's precise use case is when you want to save user's data online. There are several advantages to this:-
Easy API to call Backup Service
No need to maintain a separate FTP server, hence reduced cost saving both domain and hosting charges.
Unlimited Backup space for your user's individual app installation.
In case the user deletes the app, your app's data can be retrieved from the Android Backup service.
The developer page gives a fair amount of idea to anyone wanting to implement that kind of data backup support cost-effectively.

Sending Google Form response programmatically via Android

I've developed a couple other apps that did nothing more than preference management, some custom lists, and LAN communications but that's about it. I'm building a employee attendance app that allows the employee to register when they clock in, lunch out, lunch in, and clock out, all via the app. Once all four have been entered, I want it to send it via a Google Form to a Google spreadsheet that I can then use to calculate there hours and have a long on all of their information.
How would I go about integrating submitting a Google Form Response programmatically in Android?
Thanks in advance, -John
A Google Form is just a fancy UI for having users submit responses which get stored as a Google spreadsheet. That's it - there's nothing special about it. To accomplish this on Android you just need to setup your UI with the appropriate widgets to capture responses. Then save that data to a Google spreadsheet.
To work with the Google Spreadsheet API you can check out this guide from Google.

Storing simple information in online database in android

I am programming android app and I need to store simple data on server. I need to store only users email address, his nickname, and who invited him to the app. Is there some way how to do it, instead of setting my own server?
I was searching for some simple way, like some easy API for sending it to google server, so I wouldn't need to care about security.
You may use Parse for storing data upto 1Gb for free. Also see https://parse.com/products/data. I heard from those who used it, that the API is quite straight forward.

How to sync android database with web database?

Hi I want to sync android database with web database, my scenario is:
I want to make an android app dictionary. The dictionary words are added by web forms and the user android consume those words. In the Android application I have the historical of words that the user displayed and data of their studies, that should be synchronized online in case of change user phone or him have multiple devices.
My question is how to do that:
I need authentication or can get the User's google account to identify him?
How should I synchronize these two databases?
If I use Backup API i can get the same data in diferents devices?
I need authentication or can get the User's google account to identify him? That's your decision. You could even provide both methods. Some people don't want to share everything with Google, others don't care. If you want to create your own authenticator read the Udinic blog post about it.
How should I synchronize these two databases? You need a sync adapter in Android and a receiving service in your web application. In the Udinic blog there is also a tutorial about sync adapters. On server side you could create a REST service for example.
If I use Backup API i can get the same data in differents devices? The Backup API doesn't seem to be the right choice as it only restores data during the initial setup and I assume you want to synchronize the data all the time.

Feedback from user to developer without involving Google Play

I want users to send textual feedback to myself(the developer) directly(without involving Google Play).
Hence, I can get the suggestions to improve my app directly to myself, instead of users writing negative reviews on Google Play.
I do not own a website nor have access to any server.
I do not want to use ACTION_SEND, as that opens an email app.
I'm an android beginner and this is my first app.
Maybe that data can be stored in a database(on cloud, common to all users) that I can access at any time I want?
After researching, I think GCM is supposed to be used, but I no idea how to go about it.
Please tell me the easiest way to implement this.
Thank You.
That is not what exactly what GCM is for. GCM is primarily for sending data from the cloud to the the devices.
You are correct in thinking that one option is to store the data in a database in the cloud. You could use http://pythonanywhere.com free account and build a web app that provides you endpoints which will save and retrieve data to a SQLite db pretty easily (if you have knowledge of python and server side web concepts).
Another perhaps simpler option is to use a pre-existing cloud database solution http://www.parse.com is a cloud backend that also has a free-to-use option that you can use to store arbitrary data. It is pretty easy to get up and running if you follow their many nice Android tutorials.
One last option I will present is to use a Google Spreadsheet with a Form associated to it. Once you create a form if you know the right url and parameters you can send a post request to insert arbitrary data into your spreadsheet. I've created a library that simplifies the process of uploading. GoogleFormUploader. If you need help getting your form set up you can watch the relevant portion of my video tutorial covering this topic

Categories

Resources