1 Reply Latest reply on Feb 12, 2009 3:39 PM by 843849

    CDC Development


      I am using netbeans 6.5 for CDC development and I want to develop a simple application which should have more than one form like a login form and then menu and so on
      i tried using 2 JFrames but getting error
      java.lang.UnsupportedOperationException: Cannot create more than one window per graphics device
      Or else
      can anyone tell how to implement such application

      Thank You
        • 1. Re: CDC Development
          Try to put new form at new panel... not on new frame.
          Jumping from one form to another will be then represented with switching the panels in the same frame.

          something like this:

          JFrame jf; // reference to jour frame

          JPanel jpNew = new JPanel();

          // ... populate new JPanel with swing components ...

          jf.remove(jf.getContentPane()); // remove