2

I made a subclass of button called Block for a minesweeper like game. I then made a 2d array of this class. Is there an easy way to display this array in a grid?

Thanks

1 Answer 1

1

You should use a GridView with a custom adapter. There is enough documentation available at the Android developer website

Here is a tutorial for a custom adapter. The tutorial uses a ListView, but the adapter will also work with a GridView

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.