• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Swing GUI Interface Question

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I have to create a gui interface, that doesn't have any backend functionality. It is supposed to be similiar to an address program like outlook. I have implemented all of the components except 1 - I have to display a person in the contacts/organizer. I have to create a static array & a person contstruct. Where would I place this? Inside Contact form in the text fields?

Here is the code:




[ June 02, 2008: Message edited by: Campbell Ritchie ]
 
Sheriff
Posts: 22781
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Rebecca,

please UseCodeTags in the future.

Can some bartender move this to Swing?
 
Marshal
Posts: 79151
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Morning.

Why are you assigning your static Strings to null? You want

private static final String OPEN = "Open";

or simply write "Open" where you need it.

I think your Person needs a separate class; keep your "model" and your "view" in separate classes.

Are you using FlowLayout? Watch the behaviour of your GUI if you resize it from left to right.

And Rob is right; I was going to move you to Swing anyway. Because I am feeling in a benign mood I shall add code tags so you can see how much easier it is to read.
 
I don't get it. A whale wearing overalls? How does that even work? It's like a tiny ad wearing overalls.
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic