• 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

GUI calander

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hey guys i'm new to java and i need to make GUI calendar and i don't know how. so please help me and don't get confused with the variables cos they are Ethiopian words. here is the code

 
Bartender
Posts: 5167
11
Netbeans IDE Opera Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't see anything GUI related in the code you posted. Perhaps you mean that you aren't aware of how to create a GUI? If that's so, you need to go through the Swing tutorial systematically.

And welcome to the Ranch!
 
Greenhorn
Posts: 22
Eclipse IDE Opera Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi there Habtamu:

If you only need a calendar, maybe this code can help you, but is Java SWT.

Check this snippet:
http://www.java2s.com/Tutorial/Java/0280__SWT/CreateaDateTimecalendardateandtimeinadialog.htm

Regards !!!
 
Marshal
Posts: 79265
377
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would suggest you need to go back to creating an EthiopianCalendar class and running it fom the command line before you try it in a GUI. It would appear from this that there is nothing available, but Googling for Java Ethiopian calendar, and this ad from Google might give you something to use instead.

I would suggest for your class, it looks confusing having that many fields. You should consider an enum for Ethiopian months instead of that switch block. You should avoid if (...) b = true; else b = false; It is bad style; see this link. It is also bad style and error prone to write == true or similar.
 
Yeah, but is it art? What do you think tiny ad?
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic