Take a survey

Developing Applications Using APIs > Converting Between File Formats and PDF > Converting from Native File Formats to PDF > Converting from native file format to PDF using LiveCycle Remoting

Converting from native file format to PDF using LiveCycle Remoting
To convert an HTML, Microsoft Office, AutoCAD, or other type of file to a PDF document using LiveCycle Remoting, perform the following tasks:
1.
Include the files that enable you to perform remoting. For information, see Invoking LiveCycle ES Using LiveCycle Remoting.
2.
With LiveCycle Remoting, you do this by creating a dynamic ChannelSet instance that uses the AMF channel.
3.
Create a new flash.net.FileReference instance.
Create FileReference event handlers for the Event.SELECT and DataEvent.UPLOAD_COMPLETE_DATA events.
Call the FileReference.browse method to display a file selection dialog box.
In the select event handler, create a flash.net.URLRequest instance that specifies the URL of the server script configured to handle upload through HTTP POST calls. For LiveCycle Remoting, this is http://lcserver:port/remoting/lcfileupload. Then call the FileReferences.upload method.
In the upload complete event, populate the DocumentReference instance and call a method that converts the file, as explained in the next step.
4.
Invoke the CreatePDF method, passing the ActionScript object as a parameter.
5.
In the event handler for the CreatePDF call, create an ActionScript object to contain the result.
The CreatePDF method wraps the result in an element named Result.
Retrieve the new PDF document by accessing the LiveCycle Remoting DocumentReference object in the Result element named ConvertedDoc.
Use the DocumentReference object’s url attribute to access the URL of the converted file.
View Quick Start
 

 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/livecycle/es/sdkHelp/programmer/sdkHelp/generatePdfJavaAndWSConversionsToPDF.66.5.html