iOS Question Change Label Background

Discussion in 'iOS Questions' started by Turbo3, Jul 17, 2015.

  1. Turbo3

    Turbo3 Active Member Licensed User

    In B4A we have SetBackgroundImage for a Label.

    Can the same thing be done in B4i? If so, how?

    I am hoping a modified version of this code that works for buttons would do the job.
    Code:
    Sub SetBackgroundImage(b As Button, bmp As Bitmap, state As Int)
    Dim no As NativeObject = b
    no.RunMethod(
    "setBackgroundImage:forState:"Array(bmp, state))
    End Sub
     
    Last edited: Jul 17, 2015
  2. Erel

    Erel Administrator Staff Member Licensed User

    The simplest way it to put an ImageView behind the label.
     
Loading...