I'm trying to decode the body field of the Attachment Object in salesforce doing this:
String bodyContent = documento.Body.toString();
Blob bodyDocumentoBlob = EncodingUtil.base64Decode(bodyContent);
bodyDocumento = bodyDocumentoBlob.toString();
When I try it in the application I get this error:
System.StringException: BLOB is not a valid UTF-8 string
Could anybody help me?