Skip to content

Commit c5f36d8

Browse files
committed
Updated GroupDocs.Merger up to 23.10 version.
1 parent c1624d0 commit c5f36d8

2 files changed

Lines changed: 29 additions & 0 deletions

File tree

Examples/src/main/java/com/groupdocs/merger/examples/RunExamples.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@ public static void main(String[] args) throws Throwable
136136
//CrossJoinMultipleDocuments.run();
137137
//CrossJoinMultipleImages.run();
138138
//CrossJoinPagesFromVariousDocuments.run();
139+
//CrossJoinImagesToPdf.run();
139140
}
140141
//endregion
141142

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
package com.groupdocs.merger.examples.basic_usage.multiple_document_operations;
2+
3+
import com.groupdocs.merger.Merger;
4+
import com.groupdocs.merger.examples.Constants;
5+
6+
import java.io.File;
7+
import java.nio.file.Paths;
8+
9+
/**
10+
* This example demonstrates how to join images with different file types to PDF.
11+
*/
12+
public class CrossJoinImagesToPdf {
13+
public static void run() throws Exception
14+
{
15+
String filePath = Constants.SAMPLE_PDF;
16+
String filePathOut = new File(Constants.OutputPath, Constants.SAMPLE_NAME + Paths.get(filePath).getFileName().toString()).getPath();
17+
18+
Merger merger = new Merger(filePath);
19+
{
20+
merger.join(Constants.SAMPLE_JPG);
21+
merger.join(Constants.SAMPLE_SVG);
22+
merger.save(filePathOut);
23+
}
24+
25+
System.out.print("Source documents was merged successfully.");
26+
System.out.print("Check output "+filePathOut);
27+
}
28+
}

0 commit comments

Comments
 (0)