Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

class AptComplex1implements ActionListener { JTextArea innerText1; public AptCom

ID: 3618200 • Letter: C

Question

class AptComplex1implements ActionListener
  {
           JTextArea innerText1;

           public AptComplex1RadioButtonHandler(JTextArea innerTextArea)
           {
               innerText1 = innerTextArea;
           }
           public void actionPerformed(ActionEvent t)
           {
                  innerText1.setText(s); //what kind of swing can Iuse it hear to able to set string s in it. I don't want to type astring, I want to insert a variable instead. pleasehelp

              }
        }

Explanation / Answer

innerText1.setText(s); //what kindof swing can I use it hear to able to set string s in it. I don'twant to type a string, I want to insert a variable instead. pleasehelp If Iunderstand you correctly, you want to set the text to someObject s. Try using thetoString(). Object s; innerText.setText(s.toString());