Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom layout in java, can't find multiple buttons in the layout #217

Open
zgao67 opened this issue Feb 28, 2020 · 0 comments
Open

Custom layout in java, can't find multiple buttons in the layout #217

zgao67 opened this issue Feb 28, 2020 · 0 comments

Comments

@zgao67
Copy link

zgao67 commented Feb 28, 2020

Trying to use custom layout in java
In this layout, I have 3 buttons - button 1, button 2, button3
When I click each button, it'd trigger different functions
Version is 5.0.0
I used .getLayoutContainer().findViewById(R.id.button1).setOnClickListener(new View.OnClickListener() {
....., it worked for button1.
But i can't do another .getLayoutContainer to find button2 or 3.
Can you help me out?
Also it'd be great if you can post some sample code for this.
Many thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant