Android Question Button.Text

Discussion in 'Android Questions' started by jinyistudio, Feb 2, 2015.

  1. jinyistudio

    jinyistudio Active Member Licensed User

    Hi

    Use RunMethod2. Could i change the text of button ? How to typing the code ?

    Code:
    Sub SetPressed(cmd As Button, Pressed As Boolean)
       
    Dim ref As Reflector
       ref.Target = cmd
         ref.RunMethod2(
    "setPressed", Pressed, "java.lang.boolean")
    End Sub
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    You can change cmd.Text = "new text"
     
  3. jinyistudio

    jinyistudio Active Member Licensed User

    Hi

    I know it(cmd.Text = "new text") but I counld't see it display on the button face sometime when I continuous updating multiple buttons as following

    Code:
    btn1.text = s1
    btn2.text = s2
    btn2.text = s3
     
  4. Erel

    Erel Administrator Staff Member Licensed User

    You can update multiple buttons. There shouldn't be any problem.
     
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