Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > Java Basics
|
Java Basics General beginning Java language questions that don't fit in one of the more specific forums. Please specify what version.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 22nd, 2009, 09:56 AM
Authorized User
 
Join Date: Feb 2009
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Default Passing JPanel to Another Class

Hello All,
First thanks for taking time to read my thread. My problem is I have created a Gui Class that contains multiple JPanels inside another JPanel or ContentPane.

I have just now created another Gui2 Class in the same java project and I would like this new Gui2 Class to read and display the main JPanel or ContentPane from the original Gui Class.

I keep on getting:
Exception in thread "AWT-EventQue-0" java.lang.NullPointerException Errors

Any suggestions?
Thanks again.
Dan
 
Old May 29th, 2009, 05:50 AM
jomet
Guest
 
Posts: n/a
Default

Quote:
Originally Posted by d-mart View Post
Hello All,

I have just now created another Gui2 Class in the same java project and I would like this new Gui2 Class to read and display the main JPanel or ContentPane from the original Gui Class.
How you are reading this main JPanel?
put some code also...





Similar Threads
Thread Thread Starter Forum Replies Last Post
How to paste a bitmap into a JPanel? AndrewH Java GUI 1 May 1st, 2007 12:19 AM
JPanel components on same line biffta Java GUI 2 September 1st, 2005 06:18 PM
Can I add a JComboBox twice to the same jpanel david.byrne Java GUI 4 May 14th, 2005 11:42 AM
Passing Class object to WS r_ganesh76 .NET Web Services 4 October 4th, 2004 11:12 PM
Passing a class by reference James Diamond VB How-To 13 February 16th, 2004 06:07 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.