Android Question [B4XPages] Delete view, dynamically created.

vecino

Well-Known Member
Licensed User
Longtime User
Hi, how can I delete a view created dynamically?
Thank you.

B4X:
Sub Label6_Click
    Dim pnTr As Panel
    pnTr.Initialize("pnTr")       
    pnTr.Elevation=3dip
    pnTr.Tag=1   
    '   
    Root.AddView(pnTr,0,0,100%x,100%y)   
End Sub

Sub pnTr_Click
    For Each v As B4XView In Root.GetAllViewsRecursive
        If v Is Panel Then
            Dim pn As Panel = v
            If 1=pn.Tag Then
                pn.RemoveView
                Exit
            End If
        End If
    Next
End Sub
 

vecino

Well-Known Member
Licensed User
Longtime User
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
No partial wakelock.
** Activity (main) Resume **
No partial wakelock.
Error occurred on line: 313 (pgPreferencias)
java.lang.NumberFormatException: Invalid double: "[b4icancelbutton=Cancel, b4xcollections=null, b4xpages=null
, base64encodedecodeimage=null, cmbbox=(B4ASpinner): Left=0, Top=0, Width=590, Height=102, dateutils=null
, delaybeforechangeevent=0, delayindex=0, lastselectedindex=-1
, main=null, mbase=(BALayout) anywheresoftware.b4a.BALayout{77e1138 V.E...... ........ 428,467-1018,569}, mcallback=[b4xcollections=null, b4xpages=null, base64encodedecodeimage=null
, cxidioma=[b4icancelbutton=, b4xcollections=null, b4xpages=null
, base64encodedecodeimage=null, cmbbox=null, dateutils=null
, delaybeforechangeevent=0, delayindex=0, lastselectedindex=0
, main=null, mbase=null, mcallback=null
, meventname=, shcode=null, starter=null
, tag=null, uf=null, xui=null
, xuiviewsutils=null], dateutils=null, dlgquestion=[b4xcollections=null, b4xpages=null, base64encodedecodeimage=null
, dateutils=null, dummy=(View) Not initialized, main=null
, shcode=null, starter=null, uf=null
, xuiviewsutils=null]
, hsvflags=(MyHScrollView): Left=192, Top=375, Width=1536, Height=200, Tag=, hsvfondos=(MyHScrollView): Left=192, Top=375, Width=1536, Height=200, Tag=, imgfondo=(ImageView): Left=428, Top=580, Width=180, Height=102, Tag=
, imgidioma=(ImageView): Left=428, Top=354, Width=180, Height=103, Tag=, main=null, pnt=(BALayout): Visible=false, Left=0, Top=0, Width=1920, Height=1056, Tag=0
, pnt2=(BALayout): Visible=false, Left=0, Top=0, Width=1920, Height=1056, Tag=0, root=(BALayout) anywheresoftware.b4a.BALayout{94def8d V.E...... ........ 0,0-1920,1056 #15}, shcode=null
, starter=null, swpedirpassword=[b4xcollections=null, b4xpages=null, base64encodedecodeimage=null
, bc=[ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache_transparent=0
, gi=1, jme=(bitmapcreator) [ai=3, alphathresholdforcbcextraction=30, b4abmp=(Bitmap): 122 x 62, scale = 1,00
, bi=2, cache_solid=1, cache
Message longer than Log limit (4000). Message was truncated.
[/QUOTE]
 
Upvote 0
Top