Android Question fatal errore ???

ivanomonti

Expert
Licensed User
Longtime User
Hi,,,

I have this code that if I go with a manually breck everything works if you let it go I create a crash, do not understand why and where ...

error

B4X:
[INFO:CONSOLE(0)] "Application Cache Checking event", source: https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.html (0)
[getaddrinfo]: hostname=googleads.g.doubleclick.net; servname=(null); cache_mode=(null), netid=0; mark=0
[getaddrinfo]: ai_addrlen=0; ai_canonname=(null); ai_flags=1024; ai_family=2
getaddrinfo: googleads.g.doubleclick.net get result from proxy >>
[WARNING:aw_network_delegate.cc(92)] https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.appcache#-3#1
[INFO:CONSOLE(0)] "Application Cache NoUpdate event", source: https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.html (0)

code:

B4X:
Sub reloadFrames(post As List)
   
    sv.Panel.RemoveAllViews
    sv.Panel.Height = 1000dip
   
    Dim cp As Crypter
    cp.Initialize("fedcba9876543210","0123456789abcdef")

    TitleFont = Typeface.LoadFromAssets("Scratched Letters.ttf")
    AutorFont = Typeface.LoadFromAssets("StAndrew.ttf")

    xmap.Initialize
   
    xpost.Initialize
    xpost = post
       
    l = 0dip
    t = 0dip
    w = sv.Width
    h = 150dip
   
    Dim cv As Canvas
   
    Dim count As Int
   
    For Each colroot As Map In xpost
       
        count = count + 1
       
        xmap.Put(sv.Panel.NumberOfViews,colroot)
       
        Dim frame As Panel
        frame.Initialize("frame")
        frame.Tag = colroot
        frame.Color = Colors.ARGB(32,0,0,0)
        sv.Panel.AddView(frame,l,t,w,h)
       
        ' titolo post
       
        Dim s1,s2,s3 As String
        s1 = cp.decrypt(colroot.Get("title"))
        s2 = cp.decrypt(colroot.Get("autor"))
        s3 = cp.decrypt(colroot.Get("data"))
       
        Dim x As Float = Rnd(-10,10)
       
        cv.Initialize(frame)

        ' poistic title
        Dim fontsizeT As Int = fonsize(36dip,90)
        Dim fontsizeP As Int = fonsize(32dip,50)
       
        cv.DrawTextRotated(s1,frame.Width/2,(frame.Height/2)-20dip,TitleFont,fontsizeT,Colors.ARGB(235,255,255,255),"CENTER",x)
        cv.DrawTextRotated(s2,frame.Width/2,(frame.Height/2)+20dip,AutorFont,fontsizeP,Colors.ARGB(200,255,255,255),"CENTER",-x)
        cv.DrawTextRotated(s3,frame.Width/2,(frame.Height/2)+60dip,AutorFont,fontsizeP,Colors.ARGB(200,255,255,255),"CENTER",-x/2)
       
        t = t + h + 2dip
       
        sv.Panel.Height = t
           
    Next
   
    ProgressDialogHide
   
End Sub
 

ivanomonti

Expert
Licensed User
Longtime User
solved, the use of canvas in this way is not valid, but I wanted to believe :-(
 
Upvote 0
Top