java - there are three a user clicks on certain JButtons named red, blue, pink and one Jlabel -


Three users click on a user named Red, Blue, Pink, and a Jellybell on some pockets. Add the ActionListener for the button like if the button, the foreground color of the label will change accordingly

  public Zero verb (verb event e) {// if red is your jbutton (e.getname) Equals ("red")) {// change red color for red color} and if (ed. N.name (). Equals ("blue")) {// change lbl color blue}}  

Comments

Popular posts from this blog

c# - XML serialize base class without knowing derived class -

c# - UnhandledExceptionMode.ThrowException for AppDomain.UnhandledException -

udp - The relationship between MTU and size of skb in xmit function -