Android Question I don't understand this error...

Discussion in 'Android Questions' started by Troberg, May 4, 2015.

  1. Troberg

    Troberg Well-Known Member Licensed User

    Look at the attached picture. There's a few lines not needed for the error included, but I've narrowed it down to the line the error appears on.

    I understand what it proposes and why, but it doesn't work. What should I do???
     

    Attached Files:

  2. sorex

    sorex Expert Licensed User

    what's that ME.ME. thing? a typo?
     
    Troberg likes this.
  3. Troberg

    Troberg Well-Known Member Licensed User

    Nope, it's just an unlucky screen rendering of the squiggly line. It's two arguments, separated by a comma (,), not a period (.). The tail of the comma gets lost in the squiggly line.
     
  4. sorex

    sorex Expert Licensed User

    beats me then, I don't even know what library you're using there :)
     
    Troberg likes this.
  5. Troberg

    Troberg Well-Known Member Licensed User

    No library, just my own code.

    I think it has something to do with the fact that iPanOSD has a property declared as a Panel. Glob is declared in ProcessGlobals, and somehow, it doesn't like sending an object containing a GUI element as an argument to a call to it then.
     
  6. sorex

    sorex Expert Licensed User

    I can't see what that CPanOSD type is.
     
    Troberg likes this.
  7. Troberg

    Troberg Well-Known Member Licensed User

    Code below. For some reason, when I copy/paste, some spaces go missing, so if there seems to be a missing space, don't bother, it's just copy/paste error.

    Code:
    #Region Comment header
    ' CurrentVersion:
    ' Maintainer: Troberg
    'Todo
    'Currently only a stub
    'Future
    '...
    'Done
    '1.0
    '...
    #End Region
    'Class module
    Sub Class_Globals
      PrivatepPriorityAsInt = 
    8
      PrivatepPositionAsString = 
    "Center"
      PrivatepPauseMediaAsBoolean = 
    False
      PrivatepTimeToLiveAsInt = 
    3000
      PrivatepHostPanelAsPanel
      PrivatepIconAsString
      PrivatepColoringAsInt
    End Sub

    'Initializes the object. You can add parameters to this method if needed.
    Public Sub Initialize
    End Sub

    Public Sub Setup(HostPanel AsPanel)
      pHostPanel=HostPanel
      pHostPanel.Width = 
    20%x
      pHostPanel.Height = 
    20%x
    End Sub

    #Region Properties
    Sub getPriority() AsInt
      ReturnpPriority
    End Sub

    Sub getPosition() AsString
      ReturnpPosition
    End Sub

    Sub getPauseMedia() AsBoolean
      ReturnpPauseMedia
    End Sub

    Sub getTimeToLive() AsInt
      ReturnpTimeToLive
    End Sub

    Sub getIcon() AsString
      ReturnpIcon
    End Sub
    Sub setIcon(Value AsString)
      pIcon=Value
    End Sub

    Sub getHostPanel() AsPanel
      ReturnpHostPanel
    End Sub

    Sub getColoring() AsInt
      ReturnpColoring
    End Sub
    Sub setColoring(Value AsInt)
      pColoring=Value
    End Sub
    #End Region

    #Region Methods
    Sub ShowOSD(Icon AsString, Coloring AsInt)
      
    Dim bd AsBitmapDrawable
      bd.Initialize(Main.Glob.Icons.GetResizedIcon(pIcon,pColoring,
    20%x,20%x))
      pHostPanel.Background = bd
      Main.Glob.MsgHub.MsgSend1(Me, Main, Main.Glob.Messages.MA_ShowPAN, 
    "PAN", Me)
    End Sub
    #End Region
     
  8. Erel

    Erel Administrator Staff Member Licensed User

    Can you upload your project (File - Export as zip)? It will make it easier to explain the issue and the solution.
     
    Troberg likes this.
  9. Troberg

    Troberg Well-Known Member Licensed User

    Too late, I've rewritten it, it works now, but in a completely different way. Thanks anyway!
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice