trying to access 2 classes with the one JButton

I'm creating GUI's using java and trying to call 2 separate classes using the one JButton, but the last class i instantiate in the JButton code is the only one the runs,

Is there any way to run the 2 classes with the one JButton Action..
cutjackAsked:
Who is Participating?
 
91mustangCommented:
Wild geuss but maybe exception thrown, with no handling???
0
 
91mustangCommented:
post the problem code please
0
 
cutjackAuthor Commented:
private void conButActionPerformed(java.awt.event.ActionEvent evt) {
        Connect con = new Connect();
        monitor m = new monitor();                
        m.monFolder();
        con.Responder();      
       
    }
0
Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

 
copyPasteGhostCommented:
that code should work
are you sure monFolder() is not being executed?
are there any errors you are receiving?
Ghost
0
 
91mustangCommented:
Really should not be a problem with that code...
0
 
91mustangCommented:
What is monFolder()  trying to do?
0
 
cutjackAuthor Commented:
monFolder monitors incoming messages to an Inbox
0
 
copyPasteGhostCommented:
add a print line to that method and see what happens (monFolder)
Ghost
0
 
91mustangCommented:
make sure the line is the first line of the method
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.