Im trying to make a simple program.It just has a couple JButtons and JTextFields,
but its looks kinda odd, and I was wondering how to change their size.

Thanks In advance
Scheppy

Recommended Answers

All 2 Replies

to change JButton size:
ButtonName.setPreferredSize(new Dimension(buttonWidth, buttonHeight));

Thanks alot, code works perfect

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.