Can anybody help with this error?
Getting close, With PDFWriter I can save a jpg to pdf, but only small pics like icons, if I take a picture with the camera and save it to jpg, load it to pdfwriter and try to save as pdf, I get this error:
Thank you:
SoyEli
PDFWriter has been initialized.
main_makedoc (java line: 374)~e:java.lang.OutOfMemoryError
at java.io.ByteArrayOutputStream.expand(ByteArrayOutputStream.java:91)
at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:216)
at com.rootsoft.pdfwriter.ASCII85Encoder.putByte(ASCII85Encoder.java:253)
at com.rootsoft.pdfwriter.ASCII85Encoder.write(ASCII85Encoder.java:213)
at com.rootsoft.pdfwriter.XObjectImage.encodeImageData(XObjectImage.java:115)
at com.rootsoft.pdfwriter.XObjectImage.processImage(XObjectImage.java:131)
at com.rootsoft.pdfwriter.XObjectImage.<init>(XObjectImage.java:43)
at com.rootsoft.pdfwriter.PDFWriter.addImageKeepRatio(PDFWriter.java:97)
at com.rootsoft.pdfwriter.PDFWriter.addImageKeepRatio(PDFWriter.java:93)
at com.rootsoft.pdfwriter.myPDFWriter.addImage2(myPDFWriter.java:85)
at b4a.example.main._makedoc(main.java:374)
at b4a.example.main._mnumakedoc_click(main.java:385)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:187)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:171)
at b4a.example.main$B4AMenuItemsClickListener.onMenuItemClick(main.java:191)
at com.android.internal.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:147)
at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:874)
at com.android.internal.view.menu.MenuPopupHelper.onItemClick(MenuPopupHelper.java:177)
at android.widget.AdapterView.performItemClick(AdapterView.java:299)
at android.widget.AbsListView.performItemClick(AbsListView.java:1113)
at android.widget.AbsListView$PerformClick.run(AbsListView.java:2904)
at android.widget.AbsListView$3.run(AbsListView.java:3638)
at android.os.Handler.handleCallback(Handler.java:733)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5057)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:602)
at dalvik.system.NativeStart.main(Native Method)