kerou / java-html2image

Automatically exported from code.google.com/p/java-html2image
0 stars 0 forks source link

Load HTML from local or remote Path #22

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. 
imageGenerator.loadUrl("\\\ServerName\\LinePlacementProject\\HTML_LineImage.html
");
imageGenerator.saveAsImage("\\\ServerName\\LinePlacementProject\\LineImage.png")
;

2. imageGenerator.loadUrl("D:\\Test 
Envirnoment\\LinePlacementProject\\HTML_LineImage.html");
imageGenerator.saveAsImage("D:\\LinePlacementProject\\LineImage.png");

3.

What is the expected output? What do you see instead?
PNG generated image is expected , following error is thrown

Exception in thread "main" java.lang.RuntimeException: Exception while loading 
D:\Test Envirnoment\LinePlacementProject\HTML_LineImage.html
    at gui.ava.html.image.generator.HtmlImageGenerator.loadUrl(HtmlImageGenerator.java:60)
    at SSIS.ImageConverstion.main(ImageConverstion.java:10)
Caused by: java.net.MalformedURLException: unknown protocol: d
    at java.net.URL.<init>(Unknown Source)
    at java.net.URL.<init>(Unknown Source)
    at java.net.URL.<init>(Unknown Source)
    at javax.swing.JEditorPane.setPage(Unknown Source)
    at gui.ava.html.image.generator.HtmlImageGenerator.loadUrl(HtmlImageGenerator.java:58)

What version of the product are you using? On what operating system?

Eclipse JDK 7 Windows 7

Please provide any additional information below.

none

Original issue reported on code.google.com by Abubakar...@gmail.com on 29 Nov 2014 at 2:17

GoogleCodeExporter commented 9 years ago
What version of the product are you using? On what operating system?
html2image-0.9.jar
JDK 7 
Windows 7
Eclipse Luna

Original comment by Abubakar...@gmail.com on 29 Nov 2014 at 2:21