Hello everyone,
I have a strange problem when trying to open svg image
When I try to run this in the S40 3rd Edition Emulator I get an Exveption:Code:private SVGImage img; private SVGAnimator animator; private InputStream inputLogo=null; private Canvas animatorCanvas; public SplashScreen() { try { inputLogo = this.getClass().getResourceAsStream("/splashscreen_customizable.svg"); } catch (Exception ex) { ex.printStackTrace(); } try { img = (SVGImage) SVGImage.createImage(inputLogo, null); } catch (IOException ex) { ex.printStackTrace(); }
Using Maximum simulated domain
java.io.IOException
at javax.microedition.m2g.SVGImage.createImage(+95)
When I look at the "Details" in the Emulator it says NullPointerException, however.
What could be the problem?
The SVGImage is located in the root of my jar
When I debug this on Sony-Ericsson:
My InputStream has an attribute called "handle" which is set to 0.
On S40 3rd Edition FP 1 i the same attribute has the value of "null".
In both cases the attribute size is read correctly.

Reply With Quote

