constructor with input from user

i am trying to make a gui using core java and am using a constructor pdfreader() which takes string as an argument but i want the user to input a name in my gui and then pass it to the constructor . to make it interactive.

  1. i have tried using getText() to store the user input into a varaible wtih quatations and then pass it the constructor but it didnt worked ,
  2. flipped thru herbert shlidt couldnot find sth helpful.
    sm1 please help me solve the problem. ihave een stuck with it for very long time.

Source: java

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.