User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the Java section within the Software Development category of DaniWeb, a massive community of 391,941 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,902 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Java advertiser: Lunarpages Java Web Hosting
Views: 186 | Replies: 4 | Solved
Reply
Join Date: Sep 2007
Posts: 3
Reputation: tro is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
tro tro is offline Offline
Newbie Poster

Passing Info Between Forms

  #1  
Apr 14th, 2008
I am passing information between two forms. Up to now, I have passed information from one form to another. Is there another way to do this?

[DisplayDie dpDie = new DisplayDie(dp); // Getting constructor error in this line
DisplayPanel dp = new DisplayPanel(dpDie,dpDie);]

When I swap the lines, error moves to top line.

[DisplayPanel dp = new DisplayPanel(dpDie,dpDie); // Getting constructor error in this line lineDisplayDie dpDie = new DisplayDie(dp); ]
AddThis Social Bookmark Button
Reply With Quote  
Join Date: May 2007
Location: USA
Posts: 2,599
Reputation: Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice 
Rep Power: 11
Solved Threads: 257
Featured Poster
Ezzaral's Avatar
Ezzaral Ezzaral is offline Offline
Posting Maven

Re: Passing Info Between Forms

  #2  
Apr 14th, 2008
That depends entirely on the constructors you have written for DisplayDie and DisplayPanel.
Reply With Quote  
Join Date: Sep 2007
Posts: 3
Reputation: tro is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
tro tro is offline Offline
Newbie Poster

Re: Passing Info Between Forms

  #3  
Apr 14th, 2008
Signatures of each are:

[public DisplayPanel(final DisplayDieInterface l, final DisplayDieInterface r){...]

[public DisplayDie( final DieDisplayInterface s){ ..]
Reply With Quote  
Join Date: May 2007
Location: USA
Posts: 2,599
Reputation: Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice Ezzaral is just really nice 
Rep Power: 11
Solved Threads: 257
Featured Poster
Ezzaral's Avatar
Ezzaral Ezzaral is offline Offline
Posting Maven

Re: Passing Info Between Forms

  #4  
Apr 14th, 2008
You have both DieDisplayInterface and DisplayDieInterface shown there - which is it?

The fact that the confusion arose at all is a clear sign that you should consider a better name for the interface. Is there more than one class that implements the interface? If not, will there be? If both answers are no then you don't even need a separate interface definition.
Reply With Quote  
Join Date: Sep 2007
Posts: 3
Reputation: tro is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
tro tro is offline Offline
Newbie Poster

Re: Passing Info Between Forms

  #5  
Apr 14th, 2008
I have corrected, thank you for your assistance
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb Java Marketplace
Thread Tools Display Modes

Other Threads in the Java Forum

All times are GMT -4. The time now is 8:46 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC