aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes layered Pane issues Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "layered Pane issues" Watch "layered Pane issues" New topic
Author

layered Pane issues

Marco Salazar
Greenhorn

Joined: Jun 11, 2009
Posts: 2
Hi guys,

I'm trying to set one JPanel into JLayered Pane. I've tried everything I found in google but still no working. I want this new JPanel to be added to the JLayered Pane when the useres click a JMenu. Can someone give me some tips to get this done? Thanks in advance for your help
Campbell Ritchie
Sheriff

Joined: Oct 13, 2005
Posts: 38334
    
  23
Welcome to JavaRanch
We usually discuss that sort of question in our Swing forum. Moving.
Maneesh Godbole
Saloon Keeper

Joined: Jul 26, 2007
Posts: 10246
    
    8

How are you adding the JPanel? Have you set the depth? If not please go though this http://java.sun.com/docs/books/tutorial/uiswing/components/layeredpane.html
If yes, can you please show us your code where you are adding the JPanel?


[How to ask questions] [Donate a pint, save a life!] [Onff-turn it on!]
Marco Salazar
Greenhorn

Joined: Jun 11, 2009
Posts: 2
Hi guys,

I'm creating my GUI using the drag &drop option from netbeans and it generates the code automatically. Btw, the Jpanel I'm trying to add is from other class.
Here is the code I have, thnx a lot for all your help. Also I try the link you gave me but it didn't work.

Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19670
    
  18

Marco Salazar wrote:I'm creating my GUI using the drag &drop option from netbeans and it generates the code automatically.

Quit doing that immediately. You'll learn absolutely nothing that way, and the code created by your IDE is usually quite horrendous to read.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: layered Pane issues