hi, im pretty new to GUI programming but not java...
i have an applet which basically displays about 30 checkboxes for user to check
then there are some textfields to be typed in
after that is done the user clicks "Submit"
when the submit button is clicked, i would like to call a method where all the users info will be used to query a database.
How do i make it so that i can iterate through a container which has the checkboxes which the user checked and the values of the textfields.
/*sample code of what i have
this gives 5 checkboxes...checks if they should be checked by default and return checked or not
then im putting it in a collection of checkboxes..
I DO NOT KNOW where to go from here ... after the for loop, what do i do to retrieve
if the button was checked or not by the user?*/
for(int x = 0 ; x < 10; x++)
JCheckBox check = gui.checkDefaultsArray1(array,x);
boxesF1[x] = new JCheckBox(array[x],true);
c.ipady = 0;
c.gridx = 0;
c.gridy = x+5;
countF1 = x+5;
THANK YOU VERY MUCh!!!