Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.sction.support.office;
 
 import java.io.File;
 
 
public class OpenOfficeImpl extends Office2Swf {
	private static final Logger logger = Logger.getLogger(OpenOfficeImpl.class);
	public OpenOfficeImpl(String docFilePathString filename) {
		super(docFilePathfilename);
	}

doc文件转换成pdf文件

Parameters:
docFilePath
pdfFilePath
	public void convertDOC2PDF() throws ConnectException {
		File inputFile = new File();
		File outputFile = new File();
		// connect to an OpenOffice.org instance running on port 8100
		try {
			connection.connect();
			// convert
					connection);
			converter.convert(inputFileoutputFile);
catch (ConnectException cex) {
			.error(""cex);
			throw cex;
finally {
			// close the connection
			if (connection != null) {
				connection.disconnect();
				connection = null;
			}
		}
	}
New to GrepCode? Check out our FAQ X