views:

21

answers:

1

I have set an event successfully using

myEntry.setTitle(new PlainTextConstruct("TEST"))
myEntry.setContent(new PlainTextConstruct("See how much text will fit in there"))

Then I have successfully read the event record.

This works

myTitle = ret.getTitle().getPlainText()

But this throws an error

myTitle = ret.getContent().getPlainText()

groovy.lang.MissingMethodException: No signature of method:
com.google.gdata.data.TextContent.getPlainText()

No better if I make it

myTitle = req.getContent().toString()

Any ideas what I have missed??

+1  A: 

Try:

myContent = ret.getTextContent()

or:

myContent = ret.getPlainTextContent()
wok
It does.. If you do ret.getContent().getType() it returns 1 indicating it is text
john renfrew
It is the getPlainText() that throws that exception
john renfrew
Fixed.. Thanks Just needs myContent = ret.getPlainTextContent()
john renfrew