Android Question [sloved]why BringToFront and SendToBack no effect

Discussion in 'Android Questions' started by Maodge, Jul 12, 2019.

  1. Maodge

    Maodge Member Licensed User

    Hello Alls,
    In project, I try to a imageview and a label on a button. code like this
    Code: set
        Button1.SendToBack set
        ImageView1.BringToFront set
    test on android 4.X ,it display ok.
    but on android 8.0 (huawei), it does not display img and label text.
    So why button BringToFront and SendToBack no effect ?

    and thanks

    I test using a label replay button like. And project on android 8.0 (huawei),
    img and text display ok.

    Code: set

    'use label replace button
        Button1.Visible =False
    Dim lbl As Label
    Dim cd2 As ColorDrawable
        lbl.Background = cd2
        lbl.SendToBack set
        ImageView1.BringToFront set

    Attached Files:

    Last edited: Jul 12, 2019
  2. Brandsum

    Brandsum Well-Known Member Licensed User

    Use CSBuilder to add image inside a button
    Maodge likes this.
  3. DonManfred

    DonManfred Expert Licensed User

    Put the label and img in a panel and set its elevation.

    Attached Files:

      File size:
      12 KB
    BillMeyer and Maodge like this.
  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