Results 1 to 7 of 7
Thread: Countdown Program Help!
- 05-22-2012, 11:52 AM #1
Member
- Join Date
- May 2012
- Posts
- 7
- Rep Power
- 0
Countdown Program Help!
I am not new to the programming, nor to the Java programming,
but I'm not really sure how to "construct" a countdown program.
This isn't really for the "New To Java".. but, anyways.
The goal is, when I open the program a small frame comes and
counts down the days left to an already programmed date(for
example 20 june, the end of the school days!)
and displays them to the user on the small frame.
Some tips, maybe?
Also, I am aware how to use the calendar.DATE; calendar.DAY_OF_MONTH and calendar.MONTH.
Thanks,
--Alexander
- 05-22-2012, 12:28 PM #2
Re: Countdown Program Help!
Swing? AWT? SWT? JavaFX? Something else?
First decide on your GUI toolkit. Then find a tutorial (there are good tutorials for Swing and JavaFX; don't choose the rather obsolete AWT) and learn how to build a GUI.
Once you know that, try to learn and apply at least some of the principles of MVC (Model-View-Controller) architecture.
dbWhy do they call it rush hour when nothing moves? - Robin Williams
- 05-22-2012, 12:33 PM #3
Moderator
- Join Date
- Apr 2009
- Posts
- 10,448
- Rep Power
- 16
Re: Countdown Program Help!
Have you got the code that calculates days?
That's where I'd start.
Then, presuming you wrote it as a method returning a value, you can just plug that into whatever front end you choose.Please do not ask for code as refusal often offends.
- 05-22-2012, 06:44 PM #4
Member
- Join Date
- May 2012
- Posts
- 7
- Rep Power
- 0
Re: Countdown Program Help!
s?
That's where I'd start.
Then, presuming you wrote it as a method returning a value, you can just plug that into whatever front end you choose.[/QUOTE]
First, the GUI (.. and by the way I think swing's the best option right now..) is not really important right now.
The WAY to implement the core counting (Maybe using calendar) is the prob'. I think everyone will agree, that the GUI will be easily done,
there are many ways to construct a GUI in Java and hook it to other part of the program.
REAL problem, as already stated is s?.
I think.. I can just use calendar.DATE_OF_MONTH and calendar.MONTH and some simple substraction.. I'll experiment.
--Also, DarilBurke, thanks for your help but, there is one REALLY important thing in the java programming :
Never mix the GUI with the other processes.Last edited by alllks; 05-22-2012 at 07:07 PM.
- 05-22-2012, 06:47 PM #5
Member
- Join Date
- May 2012
- Posts
- 7
- Rep Power
- 0
Re: Countdown Program Help!
Again, I would like to thank for the fast answers.
- 05-23-2012, 09:43 AM #6
Moderator
- Join Date
- Apr 2009
- Posts
- 10,448
- Rep Power
- 16
Re: Countdown Program Help!
Without code, it'll be hard for us to point out where your problem lies (even if it's simply pseudo code).
Having code gives us a chance to see where you think you should be going with the problem, otherwise all we would be able to do is write it for you, which I'm sure isn't your aim.
ETA: Oh, and no need to be quite so shouty...:)Please do not ask for code as refusal often offends.
- 07-27-2012, 04:18 PM #7
Member
- Join Date
- May 2012
- Posts
- 7
- Rep Power
- 0
Similar Threads
-
Java Countdown Timer
By JayB in forum New To JavaReplies: 2Last Post: 05-12-2011, 03:17 AM -
10 seconds countdown on console
By eLancaster in forum New To JavaReplies: 4Last Post: 04-08-2011, 06:46 PM -
writing a countdown using java
By stevie171 in forum New To JavaReplies: 7Last Post: 12-01-2010, 04:52 PM -
countdown timer, little help with method
By sidy in forum New To JavaReplies: 22Last Post: 07-19-2008, 12:42 PM -
CountDown timer
By Seema Sharma in forum AWT / SwingReplies: 1Last Post: 03-06-2008, 04:26 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks