Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to put and detect events in my grid

Status
Not open for further replies.

papaboy2

MIS
Jan 28, 2003
52
PH
hi, how can i put click event to my java application if i'm using the gridbaglayout , how can i detect the button("C") was click from other button and execute the event, i'm a novice in java, thanks very much, here is my code:

button = new JButton("C");
if (shouldWeightX) {
c.weightx = 0.5;
}
c.gridwidth = 1;
c.gridx = 0;
c.gridy = 1;
pane.add(button, c);
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top