troubleshooting Question

A question about manipulating spreadsheets/documents in google docs

Avatar of errang
errangFlag for Afghanistan asked on
PythonScripting LanguagesProgramming Languages-Other
7 Comments1 Solution767 ViewsLast Modified:
Hey,

       I am trying to edit spreadsheets available on google docs, and I looked at the google API for python... and found this code snippet:

def ListUpdateAction(gd_client, key, wksht_id, index, row_data):
  feed = gd_client.GetListFeed(key, wksht_id)
  entry = gd_client.UpdateRow(
      feed.entry[string.atoi(index)],
      StringToDictionary(row_data))
  if isinstance(entry, gdata.spreadsheet.SpreadsheetsList):
    print 'Updated!'

I understand that the gd_client variable expects a connection object.

I'm fairly sure that the index variable expects the row number, and row_data expects the data you want to put in the row.

But the thing that confuses me is what is the key and wksht_id variables for? How are they different? The explanation for this function was sparse at best (at least sparse enough that I couldn't understand it properly)... so I was hoping someone could explain what these variables meant.

Appreciate any help on this.
ASKER CERTIFIED SOLUTION
applep

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 7 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 7 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros