Reputation: 4300
In my app i am doing movie theaters. And i have a lot of custom button(seats). All button have custom id. I know the all id from saloon. I want to get my view when
i get the id.How can i do that? I dont want to get when i click.
View v=findViewById(Mycustomid)
is not working. Any suggestion? When i get the view i will change background.Can anybody help me please?
Thanks
Upvotes: 0
Views: 128
Reputation: 132982
To get using id's assigned by code use parent view object in which you are adding views dynamically like:
View v=View_object_in_which_Mycustomid_added.findViewById(Mycustomid)
Upvotes: 1