How to create a generic popup window class.

Posted on 2001-06-21
Last Modified: 2006-11-17
Hi all,

I have a Main class called called i want to create a inheritence class called class should be responsible for firing off a small window in the MainWindow for any three conditions.

These conditions are to be in three classes which are inherited from, they are this class should fire off an error message with a simple OK button to ackknowledge - just a simple message with a OK to acknowledge. - this is a popup which comes up where the user enters text and pressing OK adds it to a menu for example.

I would appreciate detailed answers from the experts on how to create these classes with code, or pointers to web pages which are specific to what i want. I will initially put this up for 100 points.

thanks in advance

Question by:flix
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Accepted Solution

dbaora earned 100 total points
ID: 6214384
you can user the JOptionPanel instead.
It has showMessageDialog() function, shich shows a message dialog, showConfirmDialog funcion and other nice stuff.
You can create your own panel and use it in the JOptionPane Dialog, thus extending its capabilites without having to implement all from the begining.

LVL 14

Expert Comment

ID: 8950878

No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

--  points to dbaora

Please leave any comments here within the next seven days.
EE Cleanup Volunteer
If you feel that your question was not properly addressed, or that none of the comments received were appropriate answers, please post your concern in THIS thread.

Featured Post

Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

Question has a verified solution.

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

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
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…
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
Suggested Courses

623 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