Greetings, I hope you are well. I want to delete an XUI_View3D object, but I get this error and I don't know how to solve it, thanks
B4X:
Sub Panel_Touch (Action As Int, X As Float, Y As Float)
Select Action
Case Activity.ACTION_DOWN
LastX=X
LastY=y
Case Activity.ACTION_MOVE
Dim Frac As Int = 5
Dim ZFront As Int = 0
Dim ZBack As Int = -20
Dim Xi As Int = (LastX-Panel.Width/2)/Frac
Dim Yi As Int = (LastY-Panel.Height/2)/Frac
Dim Xf As Int = (x-Panel.Width/2)/Frac
Dim Yf As Int = (Y-Panel.Height/2)/Frac
P3D.AddPolygon( 1 ,Array As Point3D_Type(P3D.CtP(Xi,Yi,ZFront),P3D.CtP(Xf,Yf,ZFront),P3D.CtP(Xf,Yf,ZBack),P3D.CtP(Xi,Yi,ZBack)),xui.Color_Gray,xui.Color_White).RenderToView(Panel,Panel.Width/2,Panel.Height/2,1,1)
LastX=X
LastY=y
End Select
End Sub
B4X:
Private Sub Button1_Click
Dim location As List
location.Initialize
location.Add( 1 )
P3D.RemoveObj(location)
End Sub
B4X:
Copying updated assets files (1)
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create (first time) **
** Activity (main) Resume **
Error occurred on line: 1378 (Object3D)
java.lang.NumberFormatException: For input string: "(ArrayList) [[IsInitialized=true, X=-41.0, Y=3.0
, Z=0.0], [IsInitialized=true, X=-40.0, Y=3.0
, Z=0.0], [IsInitialized=true, X=-40.0, Y=3.0
, Z=-20.0], [IsInitialized=true, X=-41.0, Y=3.0
, Z=-20.0]]"
at sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:2043)
at sun.misc.FloatingDecimal.parseDouble(FloatingDecimal.java:110)
at java.lang.Double.parseDouble(Double.java:538)
at anywheresoftware.b4a.BA.ObjectToNumber(BA.java:695)
at b4a.example.object3d._removeobj(object3d.java:4028)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:348)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:157)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:205)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:201)
at anywheresoftware.b4a.objects.ViewWrapper$1.onClick(ViewWrapper.java:80)
at android.view.View.performClick(View.java:7259)
at android.view.View.performClickInternal(View.java:7236)
at android.view.View.access$3600(View.java:801)
at android.view.View$PerformClick.run(View.java:27900)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7559)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:935)
** Activity (main) Pause, UserClosed = true **
Last edited: