Joget DX 8 Stable Released
The stable release for Joget DX 8 is now available, with a focus on UX and Governance.
...
When generating a PDF report in Joget, you can use server-side scripts (e.g., Groovy or Java) to convert binary data to Base64 before embedding it in the PDF. This can be part of the PDF generation process
Example:
Code Block |
---|
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.Base64;
// Read binary data from the image file
byte[] imageData = Files.readAllBytes(Path.of("path/to/your/image.jpg"));
// Convert binary data to Base64
String base64ImageData = Base64.getEncoder().encodeToString(imageData);
// Now you can use 'base64ImageData' for embedding in the PDF |
...
Note |
---|
Ensure that you adapt the code to your specific use case, and consult Joget's documentation or community forums for the latest information and best practices. |
...