Search:

Type: Posts; User: ahmed2009

Search: Search took 0.13 seconds.

  1. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    Ok thank you a lot man , I will try to solve it . Thanks so much for helping .
  2. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    No now I used one class only , and this is the whole code : (can you please tell me where to change to make the layout looks like in the above picture ? ...



    package averageprogram;


    import...
  3. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    You must understand first I was used two classes one for the main and one contain all the JFrame components , after I use one class (the main inside it )
    this problem happened ...
  4. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    Ok now it's show all the elements thank you , but there is one more problem the style if the program is changed look before :
    https://i.imgur.com/01w485N.png

    and after : ...
  5. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    Nothing happened, If I add these code in the main method it show me there is error :


    cp.add(panel);
    cp.add(panel1,BorderLayout.SOUTH);

    panel.add(label);
    ...
  6. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    Can you help me more , I don't get it really .
    I write this in the main method ?



    AverageProgram test = new AverageProgram();

    and what's next ?
  7. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    I use only one class , why I should create an instance ...
  8. Replies
    16
    Views
    1,421

    Re: Help in showing the elements

    It really take so much time for me to wrote it . sorry for bad formatting .
    If you copy the code and paste it , and run it , it will show only blank form without any elements . I don't know what I...
  9. Replies
    16
    Views
    1,421

    Help in showing the elements

    I write this code in one class but it doesn't show any elements ( button , labels ) all elements , but when I put it in two classes one the main and another one it works fine .

    Here is the code :...
  10. Replies
    6
    Views
    1,100

    Re: How do I center JTextField (an array!)

    Everything is solved now thanks a lot.
  11. Replies
    6
    Views
    1,100

    Re: How do I center JTextField (an array!)

    I just want when the user type in the text field it should be in the center like this :
    https://i.imgur.com/3iWBlAj.png
  12. Replies
    6
    Views
    1,100

    How do I center JTextField (an array!)

    Hello everyone ,

    I know how to do this for normal JTextField but how to do this if it an array like this :

    private JTextField[] userInput1;

    I want everything typed in the center .
Results 1 to 12 of 13