Beispiel #1
0
        public void FiletoStream(Google.Apis.Drive.v3.Data.File x, string name)
        {
            bool doesExist = System.IO.File.Exists(DependencyService.Get <ISave>().GetFileName() + "/" + name);

            if (doesExist)
            {
                FileStream    inputStream = new FileStream(DependencyService.Get <ISave>().GetFileName() + "/" + name, FileMode.Open);
                FilesResource bung        = new FilesResource(driver);
                bung.Update(x, x.Id, inputStream, "application/vnd.ms-excel").Upload();
                //bung.Create(x,inputStream, "application/msexcel").Upload();
                Application.Current.Properties["Boff"] += "Uploaded: " + x.Name;
                inputStream.Close();
            }
        }