Expand my Community achievements bar.

adobe livecycle pdf doesn't work for me :(

Avatar

Former Community Member

Hello all

I've got the following java code, using the Java API:

//except the soap libraries, I am using these external jars: adobe-output-client.jar, adobe-livecycle-client.jar, adobe-generatepdf-client.jar

Properties connectionProps = new Properties();
connectionProps.setProperty(ServiceClientFactoryProperties.DSC_DEFAULT_SOAP_ENDPOINT, "http://server:port");
connectionProps.setProperty(ServiceClientFactoryProperties.DSC_TRANSPORT_PROTOCOL, ServiceClientFactoryProperties.DSC_SOAP_PROTOCOL);
connectionProps.setProperty(ServiceClientFactoryProperties.DSC_SERVER_TYPE, "WebLogic");
connectionProps.setProperty(ServiceClientFactoryProperties.DSC_CREDENTIAL_USERNAME, "someLogin");
connectionProps.setProperty(ServiceClientFactoryProperties.DSC_CREDENTIAL_PASSWORD, "somePassword");
           
ServiceClientFactory myFactory = ServiceClientFactory.createInstance(connectionProps);
           
OutputClient outClient = new OutputClient(myFactory);
                       
FileInputStream fileInputStream = new FileInputStream("C:\\Adobe\\TimeSheet_data.xml");
Document inXMData = new Document(fileInputStream);
           
PDFOutputOptionsSpec outputOptions = new PDFOutputOptionsSpec();
outputOptions.setFileURI("C:\\Adobe\\TimeSheet.pdf");
           
RenderOptionsSpec pdfOptions = new RenderOptionsSpec();
pdfOptions.setLinearizedPDF(true);
pdfOptions.setAcrobatVersion(AcrobatVersion.Acrobat_9);
           
OutputResult outputDocument = outClient.generatePDFOutput(TransformationFormat.PDF, "TimeSheet.xdp", "C:\\Adobe", outputOptions, pdfOptions, inXMData);

When I run it, I'll get the following error:

com.adobe.livecycle.output.exception.OutputException: 
While trying to lookup 'com.adobe.output.config.OutputConfigHome' didn't find subcontext 'output'. Resolved 'com.adobe' in javax.naming.NameNotFoundException

.

.

.

1. does anybody know why I am getting this error (something with jndi names on customer's server?)

2. I also used pure webservices (I've got the wsdl location) and run htmlToPdf, but the CSS was omitted and I've got pdf with simple

text and hyperlinks without images and formatting. Is it possible to get it?

Thanks for any information provided.

  Martin

2 Replies

Avatar

Level 8

Since you are using the SOAP protocol and not the EJB one, you will need to add a few more libraries to your applicaiton.  Have a look at:

http://help.adobe.com/en_US/livecycle/9.0/programLC/help/index.htm?content=000496.html

Avatar

Former Community Member

Hello

Thanks for the answer. I am using these jars at the moment:

  • adobe-livecycle-client.jar
  • adobe-usermanager-client.jar
  • wlclient.jar
  • activation.jar
  • axis.jar
  • commons-codec-1.3.jar
  • commons-collections-3.1.jar
  • commons-discovery.jar
  • commons-logging.jar
  • dom3-xml-apis-2.5.0.jar
  • jaxen-1.1-beta-9.jar
  • jaxrpc.jar
  • log4j.jar
  • mail.jar
  • saaj.jar
  • wsdl4j.jar
  • xalan.jar
  • xbean.jar
  • xercesImpl.jar
  • adobe-forms-client.jar
  • adobe-output-client.jar
  • adobe-utilities.jar

but I am still getting the same error