I want to put the buttons on my screen wherever i want, i'm not using design view. Is there any layout method or any other method i can use to reposition my buttons.PLEASE HELP!

Recommended Answers

All 4 Replies

Any layout you want. There are lots of them, see the API and read every class that ends with "Layout".

Now, if you can tell us how it should look, and/or exactly what you mean by "reposition my buttons", we might be able to better help you. Generally though, you need to remove them, then add them in their new position (regardless of the layout used).

so what i want is other arrangements than the SOUTH,or NORTH, EAST.......given by the layout manager, I'm lookin g for sth that places the button according to the X-Y coordinates, I want to be able to explicitly choose the x-y positions,

Then check the API. You're talking only about the BorderLayout, you can use "x-y coordinates" (although not as you probably think) with GridLayout and (even better but much more difficult to get correct) with GridBagLayout. If you want to use "real" coordinates (i.e. pixel locations) then set the layout to null. I strongly advise against this though.

thanks, i will see how that goes.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.