Upload File To Googledrive Programmatically Using Android API
Once I logged in gdrive I tried to upload csv file programmatically. But it throws error in service. public class Gdriveactivity extends Activity implements ConnectionCallbacks, On
Solution 1:
There are a number of methods of Creating a Google Drive File including using a CreateFileActivityBuilder to allow the user to pick exactly where on their Google Drive they would like to create the file or programmatically calling createFile() on a DriveFolder you have. Ways of retrieving the appropriate DriveFolder
include:
- Drive.DriveApi.getRootFolder() (for the public root directory)
- Drive.DriveApi.getAppFolder() (for your application private directory - the user cannot see these files, only how much storage space they take)
- through a result of Drive.DriveApi.query().
Post a Comment for "Upload File To Googledrive Programmatically Using Android API"