This example opens 2 presentations, creates a presentation based on a template, and displays the name of second presentation opened in Lotus Symphony, at last saves and closes all the presentations.
import com.ibm.symphony.javaapi.Application; import com.ibm.symphony.javaapi.presentation.Presentation; import com.ibm.symphony.javaapi.presentation.Presentations; public class PresentationsExample { public void example() { try { Application application = Application.getInstance(); Presentations presentations = application.getPresentations(); Presentation pre1 = presentations.openPresentation( "D:\\FileTypeAssociation\\test.odp", true); Presentation pre2 = presentations.addPresentation( "D:\\FileTypeAssociation\\test.otp", false, true); Presentation pre3 = presentations.openPresentation( "D:\\FileTypeAssociation\\test3.odp", true); System.out.println(presentations.item(2).getFullName()); presentations.savePresentations(); presentations.closePresentations(false); } catch (Exception e) { e.printStackTrace(); } } }
Related information