Solved

popup menu?

Posted on 1998-08-28
1
195 Views
Last Modified: 2010-03-30
Hi, in my code, I tried to popup a menu after button is
clicked. I just cannot get it work. In the mouse listen
I have code popup.show(this, e.getX(), e.getY());
the runtime error is "parent is null". What should I do?
Can sb. give me working sample code?
Thanks.
Shane
0
Comment
Question by:xiaoxiangz
1 Comment
 

Accepted Solution

by:
milen_n earned 50 total points
Comment Utility
Did you add the popup menu to your Component (or to one of its parents) before trying to show it?
add(popup);
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
copyEndy  challenge 15 55
Enhanced For loop vs ForEach Loop 4 54
stringclean challenge 26 55
GUI builder for Eclipse? 8 7
After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
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:
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.

744 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now