AnsweredAssumed Answered

Read Content

Question asked by ant_batt on Mar 25, 2010
Latest reply on Mar 26, 2010 by openpj
Hi,

I want to read a content. My code works fine for one space but for another space don't work. Space that can't I read contains is

/app:company_home/cm:portal/cm:Game/cm:Content/cm:The_x0020_Example/*/cm:050109.html
or
/app:company_home/cm:portal/cm:Game/cm:Content/cm:The_x0020_Example/cm:2009/cm:050109.html

My code, that work fine with another space, is:


WebServiceFactory.setEndpointAddress(Alfresco.ENDPOINT);
AuthenticationUtils.startSession(AlfrescoConstants.USERNAME, AlfrescoConstants.PASSWORD);
Reference ref = new Reference(AlfrescoConstants.STORE, null, "/app:company_home/cm:portal/cm:Game/cm:Content/cm:The_x0020_Example/*/cm:050109.html");
ContentServiceSoapBindingStub contentService = WebServiceFactory.getContentService();
Content[] readResult = contentService.read(
        new Predicate(new Reference[]{ref}, AlfrescoConstants.STORE, null),
   Constants.PROP_CONTENT);

Thanks

Outcomes