[RESOLVED] MicroVG error message

Hello,

I’m writing a basic MicroVG demo and I’m getting the following error message on simulator:

ej.microvg.VectorGraphicsException: MicroVG:E=-1
	at java.lang.Throwable.fillInStackTrace(Throwable.java:109)
	at java.lang.Throwable.<init>(Throwable.java:43)
	at java.lang.Exception.<init>(Exception.java:18)
	at java.lang.RuntimeException.<init>(RuntimeException.java:18)
	at ej.microvg.VectorGraphicsException.<init>(VectorGraphicsException.java:103)
	at ej.microvg.VectorImage.getImage(VectorImage.java:120)
...

I found error messages description for MicroUI here but I can’t find the counterpart for MicroVG error messages in the documentation.

Can you help me on that ?
Thanks in advance,

–Lucas

Hi Lucas,

The error codes are documented in the VectorGraphicsException Javadoc.
In your case, -1 corresponds to IMAGE_INVALID_PATH.

Please check that the image is available at that path in your project resources and that it is listed in your application *.vectorimages.list.
See Vector Images — MicroEJ Documentation

Best regards,
Rémy

Indeed I forgot the leading /.

  • Before : "images/mascot.png"
  • After: "/images/mascot.png"

Now it works ! Thanks @rlouedec for pointing the error message documentation.

Lucas

1 Like