views:

76

answers:

1

I'm trying to insert a row in my Google spreadsheet. While other functions like counting rows, columns etc work fine; inserting a row gives me 'Namespace Error'.

An exception of type DOMException was thrown, but did not get caught during the execution of the request. You will find information provided by the exception along with a stack trace below.

Stack Trace
   1. at exception origin in ...\library\Zend\Gdata\App\Base.php line 220
   2. at Zend_Gdata_App_Base->getDOM([object DOMDocument], 1, NULL)
      in ...\library\Zend\Gdata\Spreadsheets\Extension\Custom.php line 64
   3. at Zend_Gdata_Spreadsheets_Extension_Custom->getDOM([object DOMDocument])
      in ...\library\Zend\Gdata\Spreadsheets\ListEntry.php line 77
   4. at Zend_Gdata_Spreadsheets_ListEntry->getDOM()
      in ...\library\Zend\Gdata\App\Base.php line 329
   5. at Zend_Gdata_App_Base->saveXML()
      in ...\library\Zend\Gdata\Spreadsheets.php line 336
   6. at Zend_Gdata_Spreadsheets->insertRow(array('xxx', 'xxx', 'Normal', 'Lease', 'xxx', 'test', 'test'), '0Aoxxx2c')  
A: 

Hi,

I know this post is from a while back, but I figured I'd post anyway in the hopes of saving someone else time and headaches.

I was having this same problem and after a lot of debugging it turns out that it happens due to malformed XML.

If you're passing Key values with spaces in them, it will trigger this error.

I solved it by removing all the characters that might give the XML parser trouble.

Hope that helps.

Hector Partidas