Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 4 of 4

Thread: Re: linking two or more java files using menus

  1. #1
    Junior Member
    Join Date
    Sep 2011
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Smile Re: linking two or more java files using menus

    i have three java files that i want to link them using menus.can any one help?


  2. #2
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,318
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: linking two or more java files using menus

    What do you mean link them, and what are the 'java files'? Give us all the information available - make it easy for us to help you - otherwise we are left guessing which is not productive.

  3. #3
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: linking two or more java files using menus

    What does that mean? Basically, you're going to have to have a reference to an instance of ClassB inside ClassA to be able to use it. You do that by instantiating ClassB in ClassA.

    Edit- I was too slow, and I agree with everything copeg already told you.
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  4. #4
    Think of me.... Mr.777's Avatar
    Join Date
    Mar 2011
    Location
    Pakistan
    Posts
    1,136
    My Mood
    Grumpy
    Thanks
    20
    Thanked 82 Times in 78 Posts
    Blog Entries
    1

    Default Re: linking two or more java files using menus

    Well, you need menus to link those files. So, what is the problem?
    Are those three files are java forms or class files?
    If Java forms, then behind every menu, write the code to open up that form and if those are class files, i don't know if you really need to link, just instantiate the class object and start doing what you want.
    Well copeg has said right. Tell us the exact problem, so that we could help you easily.

Similar Threads

  1. Linking two JLists
    By mib1bee in forum AWT / Java Swing
    Replies: 2
    Last Post: December 30th, 2010, 02:19 PM
  2. Swing Drop Down Menus
    By x3rubiachica3x in forum AWT / Java Swing
    Replies: 2
    Last Post: November 5th, 2010, 04:58 PM
  3. Menu of Menus Help
    By Strivelli in forum Java Theory & Questions
    Replies: 10
    Last Post: June 5th, 2010, 02:40 PM
  4. Database connection using NetBeans
    By jcc285 in forum Java IDEs
    Replies: 6
    Last Post: June 9th, 2009, 03:23 AM
  5. [SOLVED] How to link two different class?
    By John in forum Object Oriented Programming
    Replies: 11
    Last Post: April 27th, 2009, 02:57 PM