I am stuck in a Java application.
I have a doubt that is there any way to convert HTML template to DOC Template with Image in HTML file using Java. I have tried Aspose API but I cant use it because it is not open.
I fetch HTML template from database and store the whole template into string and now I want this string output in a WORD DOC including the images.
Here is my piece of code:
proc_stmt = con.prepareCall("{call PROCEDURECALL(?)}");
proc_stmt.registerOutParameter(1, Types.CLOB);
proc_stmt.execute();
String htmltemplate = proc_stmt.getString(1);
I am storing the HTML template in a String and now I want it to be converted in WORD DOC. It also have a image src=local path link.The whole template is working fine but the image is not being posted so can anyone help me with it?
Thank you all for the time and help. I tried
docjx4j API 2.8.1
and it wors like wonder. It hadConvertinXHTMLinFile
and it works fine. If anyone wants the code I will post it.Here is the link that helped me : https://github.com/plutext/docx4j/blob/master/src/main/java/org/docx4j/samples/ConvertInXHTMLFile.java
Once again, Thank you all. Vrinda.