Solved

How to create a generic popup window class.

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

I have a Main class called called MainWindow.java i want to create a inheritence class called PopUpWindow.java.This 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 PoPUpWindow.java, they are

ErrorWindow.java- this class should fire off an error message with a simple OK button to ackknowledge

InfoWindow.java - just a simple message with a OK to acknowledge.

EnterText.java - 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

flix
0
Comment
Question by:flix
2 Comments
 
LVL 2

Accepted Solution

by:
dbaora earned 100 total points
ID: 6214384
Hi,
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.

regards,
dbaora.
0
 
LVL 14

Expert Comment

by:sudhakar_koundinya
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.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
sudhakar_koundinya
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.
0

Featured Post

Industry Leaders: 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!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
use lov values 2 71
ejb message driven bean mdb creation steps 2 34
java mysql insert application 14 41
dao vs facade design patterns 2 29
INTRODUCTION Working with files is a moderately common task in Java.  For most projects hard coding the file names, using parameters in configuration files, or using command-line arguments is sufficient.   However, when your application has vi…
In this post we will learn different types of Android Layout and some basics of an Android App.
Viewers will learn about arithmetic and Boolean expressions in Java and the logical operators used to create Boolean expressions. We will cover the symbols used for arithmetic expressions and define each logical operator and how to use them in Boole…
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:

679 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