Is there a way for me to manipulate the cells of a grid layout? For example lets say i have a grid that has 5 rows and 5 columns. Is it possible for me to manipulate the cell at row 1 column 2 using the layout, sort of like the way you would manipulate the cells of an array? Or is this not possible? Hope someone can help. Thanks.
IcyFire 0 Newbie Poster
Recommended Answers
Jump to PostA grid layout is just an algorithm for placing GUI objects in a container. The "cells" are just an abstract geometrical concept, so there's no meaningful way to "mainipulate" them.
What you can do is create a 5x5 array of some real objects, eg JButton[5][5] or JLabel[5][5], then use the …
Jump to PostOK, that's the kind of thing I was referring to. Although htis may seems a bit complicated to start with, in the end it will be easier to use a proper model/view structure, a simple form of MVC, in which the logic is implemented in a non-GUI model, and a …
All 5 Replies
Taywin 312 Posting Virtuoso
JamesCherrill 4,733 Most Valuable Poster Team Colleague Featured Poster
IcyFire 0 Newbie Poster
JamesCherrill 4,733 Most Valuable Poster Team Colleague Featured Poster
IcyFire 0 Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.