Solved

trying to access 2 classes with the one JButton

Posted on 2004-04-30
9
189 Views
Last Modified: 2010-03-31
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..
0
Comment
Question by:cutjack
  • 5
  • 2
  • 2
9 Comments
 
LVL 4

Expert Comment

by:91mustang
ID: 10961042
post the problem code please
0
 

Author Comment

by:cutjack
ID: 10961092
private void conButActionPerformed(java.awt.event.ActionEvent evt) {
        Connect con = new Connect();
        monitor m = new monitor();                
        m.monFolder();
        con.Responder();      
       
    }
0
 
LVL 13

Assisted Solution

by:copyPasteGhost
copyPasteGhost earned 150 total points
ID: 10961231
that code should work
are you sure monFolder() is not being executed?
are there any errors you are receiving?
Ghost
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 4

Expert Comment

by:91mustang
ID: 10961242
Really should not be a problem with that code...
0
 
LVL 4

Expert Comment

by:91mustang
ID: 10961257
What is monFolder()  trying to do?
0
 
LVL 4

Accepted Solution

by:
91mustang earned 150 total points
ID: 10961267
Wild geuss but maybe exception thrown, with no handling???
0
 

Author Comment

by:cutjack
ID: 10961271
monFolder monitors incoming messages to an Inbox
0
 
LVL 13

Expert Comment

by:copyPasteGhost
ID: 10961286
add a print line to that method and see what happens (monFolder)
Ghost
0
 
LVL 4

Expert Comment

by:91mustang
ID: 10961296
make sure the line is the first line of the method
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question