Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7852267
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T19:22:51+00:00 2026-06-02T19:22:51+00:00

I have my buttons created from my Design View in Netbeans (of type JToggleButton)

  • 0

I have my buttons created from my Design View in Netbeans (of type JToggleButton)

ex. btn00, btn01 …

I have one matrix for my grid (Memory game style):

int matriz[][] = new int [4][6];

I have another matrix for where my images are (of type ImageIcon) and I use this method to go through it:

public ImageIcon[] ArrayIconos()
{
    ImageIcon Disney[] = new ImageIcon[25];

    for (int n=0; n<25; n++)
    {
        Disney[n] = new ImageIcon("Disney"+(n+1)+".png");
        System.out.println(Disney[n]);
    }

    return Disney;

}

How could I feed my image matrix (Disney) into my matrix called matriz so I can load the images to the buttons?

Thanks for your help in advanced. Please let me know if my explanation is not clear enough.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T19:22:53+00:00Added an answer on June 2, 2026 at 7:22 pm

    Note that a memory game doesn’t need to know that the cells are arranged in a rectangular matrix; it only cares if two cells have matching images. This example uses two instances of List<GameButton>

    • buttons holds all of the memory cells.
    • selected records the current selection(s).
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created an alert view with two buttons using the following code: UIAlertView
I have a created a list view for one of my controller's index action.
I have created 4 buttons via Interface Builder. I have an array which has
I have several buttons on my app that are being created dynamically. They are
I created some widgets with jQuery UI and I notice that buttons have a
I am trying to create a rich text editor. I have created some buttons
I have associated a Button ID while generating Buttons dynamically and created a Button
I have created a Dialog with two buttons Yes, No, and then I have
i have just created a drum app. The user taps on the individual buttons
I have created button 2 below: <input id=Button1 type=button value=Stop onclick=alert('hello world');/> <input id=Button2

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.