Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7820421
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T07:16:50+00:00 2026-06-02T07:16:50+00:00

I am trying to upload a simple text file to a specific folder in

  • 0

I am trying to upload a simple text file to a specific folder in google documents but with no luck.

FileStream fileStream = new FileStream(@"c:\test.txt", System.IO.FileMode.Open);
DocumentEntry lastUploadEntry = 
    globalData.service.UploadDocument("c:\\test.txt", null);                                                                               

string feed =
    "https://docs.google.com/feeds/upload/create-session/default/private/full/folder%folder:0B2dzFB6YvN-kYTRlNmNhYjEtMTVmNC00ZThkLThiMjQtMzFhZmMzOGE2ZWU1/contents/";

var result = 
    globalData.service.Insert(new Uri(feed), fileStream, "application/pdf", "test");

I get an error saying

“The remote server returned an error: (503) Server Unavailable.”

I am suspecting that the destination folders uri is wrong but i can’t figure out the correct one.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T07:16:59+00:00Added an answer on June 2, 2026 at 7:16 am

    There’s a complete sample at https://developers.google.com/google-apps/documents-list/#uploading_a_new_document_or_file_with_both_metadata_and_content that uses the resumable upload component:

    using System;
    using Google.GData.Client;
    using Google.GData.Client.ResumableUpload;
    using Google.GData.Documents;
    
    namespace MyDocumentsListIntegration
    {
      class Program
      {
        static void Main(string[] args)
        {
          DocumentsService service = new DocumentsService("MyDocumentsListIntegration-v1");
    
          // TODO: Instantiate an Authenticator object according to your authentication
          // mechanism (e.g. OAuth2Authenticator).
          // Authenticator authenticator =  ...
    
          // Instantiate a DocumentEntry object to be inserted.
          DocumentEntry entry = new DocumentEntry();
    
          // Set the document title
          entry.Title.Text = "Legal Contract";
    
          // Set the media source
          entry.MediaSource = new MediaFileSource("c:\\contract.txt", "text/plain");
    
          // Define the resumable upload link
          Uri createUploadUrl = new Uri("https://docs.google.com/feeds/upload/create-session/default/private/full");
          AtomLink link = new AtomLink(createUploadUrl.AbsoluteUri);
          link.Rel = ResumableUploader.CreateMediaRelation;
          entry.Links.Add(link);
    
          // Set the service to be used to parse the returned entry
          entry.Service = service;
    
          // Instantiate the ResumableUploader component.
          ResumableUploader uploader = new ResumableUploader();
    
          // Set the handlers for the completion and progress events
          uploader.AsyncOperationCompleted += new AsyncOperationCompletedEventHandler(OnDone);
          uploader.AsyncOperationProgress += new AsyncOperationProgressEventHandler(OnProgress);
    
          // Start the upload process
          uploader.InsertAsync(authenticator, entry, new object());
        }
    
        static void OnDone(object sender, AsyncOperationCompletedEventArgs e) {
            DocumentEntry entry = e.Entry as DocumentEntry;
        }
    
        static void OnProgress(object sender, AsyncOperationProgressEventArgs e) {
            int percentage = e.ProgressPercentage;
        }
      }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm currently trying to upload a csv file to a database through simple html
I'm trying to do a simple file upload using objective c and NSUrlRequest. My
I am trying to make a simple upload file system, and this is my
I have been trying to upload a .txt to my server via a simple
I'm trying to make a really simple file upload using jQuery, without having to
PHP beginner working from a tutorial. I'm trying to do a simple upload from
I am trying to upload a file or stream of data to our web
I'm trying to upload an application to the iPhone App Store, but I get
I'm trying to upload documents to SharePoint using web services attaching custom metadata to
I'm trying to upload a file to scribd. It says: The contents of the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.