Computer Science Canada 12 hour clock instead of 24? |
Author: | commandos [ Sat May 10, 2008 10:33 am ] |
Post subject: | 12 hour clock instead of 24? |
I've been trying to make an alarm clock and I want it to be in a 12 hour clock instead of 24. Is there anyway that I can get the hour, minute and seconds separately so i can have a variable for each? |
Author: | gitoxa [ Sat May 10, 2008 12:41 pm ] |
Post subject: | RE:12 hour clock instead of 24? |
The time function puts the time into a string variable, just use string manipulation to take out each part of the time. |
Author: | commandos [ Sun May 11, 2008 12:02 pm ] |
Post subject: | RE:12 hour clock instead of 24? |
haha, ya i took computer science 2 years ago and im just doing a little project on my own right now. Completely forgot you can get certain parts of the string. Thanks, i got it now. |