Hi Neal,
To upload/create a new document with attached plaintext content,
you can follow the process for uploading a word doc:
http://code.google.com/apis/documents/docs/1.0/developers_guide_python.html#UploadingWPDocs

Instead, create the MediaSource with a StringIO object.  See the unit tests:
http://code.google.com/p/gdata-python-client/source/browse/trunk/tests/gdata_tests/docs/service_test.py#333

If you want to replace the entire document's content, don't include the
append=true parameter.
That's your first link:
http://code.google.com/apis/documents/docs/1.0/developers_guide_python.html#UpdatingReplaceContent

Eric

On Wed, Aug 12, 2009 at 3:32 AM, NealWalters <nealwalt...@nealwalters.com>wrote:

>
> Got it to work by changing new_entry to created_entry in this line:
>
>   updated_entry = client.Put(ms, created_entry.GetEditMediaLink
> ().href + '?append=true')
>
> But I would still like to know if you can set the text at the same
> time you create the document?
>
> Also, what if you wanted to replace the entire text of the document
> instead of just append?
>
> Thanks,
> Neal
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Docs Data APIs" group.
To post to this group, send email to Google-Docs-Data-APIs@googlegroups.com
To unsubscribe from this group, send email to 
google-docs-data-apis+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/Google-Docs-Data-APIs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to