Android Question Find Instance

Discussion in 'Android Questions' started by fishwolf, May 30, 2015.

  1. fishwolf

    fishwolf Active Member Licensed User

    If i draw the graphics interface to runtime, for example a button

    and define the instance of button into a function or method.

    can i find the instance of button into activity into other function or method?

    Thanks
     
  2. DonManfred

    DonManfred Expert Licensed User

    You must be much more precise with your description of your problem.
    Put the button reference into a map for example after you created it...
     
  3. RandomCoder

    RandomCoder Well-Known Member Licensed User

    Another option is to use the Tag to store a string or integer value to identify the view by. You can itterate through all the views to find the one you want or use Sender to take a reference to a view that has been clicked for example.
     
  4. DonManfred

    DonManfred Expert Licensed User

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