TodayPlus Boards v2

TodayPlus for the Pocket PC Forums => Help and Support => Topic started by: Anonymous on October 24, 2003, 05:59:53 AM

Title: time command question
Post by: Anonymous on October 24, 2003, 05:59:53 AM
Hi

I'm trying to display the current date and time. Using the comand time,5,0,-1,5,l,"dddd, MMMM d, yyyy   hh, mm, ss, tt" displays the date and then hh mm ss tt. What am I doing wrong??

Also, is there a way to call an external program say clock.exe other than using the launcher? I'd like to reproduce the PCC's date plugin, using the clock icon to call clock.exe and I'm not sure how to do this.

Thanks a lot to whoever takes the time to reply. I'm having a lot of fun with this program!
Title: Re: time command question
Post by: arbitrajeu on October 24, 2003, 06:04:05 AM
Quote from: AnonymousI'm trying to display the current date and time. Using the comand time,5,0,-1,5,l,"dddd, MMMM d, yyyy   hh, mm, ss, tt" displays the date and then hh mm ss tt. What am I doing wrong??
I haven't tried it out, but I think you need to separate date and time formats:

time,5,0,-1,5,l,"dddd, MMMM d, yyyy  "," hh, mm, ss, tt"
Title: time command question
Post by: ya1950 on October 24, 2003, 06:11:26 AM
arbitrajeu

Thanks a lot ! That indeed is the correct syntax. It works!

ya1950
Title: Re: time command question
Post by: arbitrajeu on October 24, 2003, 06:26:00 AM
Quote from: AnonymousAlso, is there a way to call an external program say clock.exe other than using the launcher? I'd like to reproduce the PCC's date plugin, using the clock icon to call clock.exe and I'm not sure how to do this.

You need to add the following to your config.txt file (or check the original shortcut named clock, if you already have one):

shortcut,clock,\Windows\clock.exe,Clock

The following will display the clock icon and load the clock on clicking it:

image,2,2,clock-today.bmp,t
button,2,2,15,15,-1,0,%clock

You need to make sure that .bmp image is in your image folder - it's from rbg08's icon set, in case you are using his skin as a base.

Hope that helps.
Title: time command question
Post by: ya1950 on October 24, 2003, 07:56:19 AM
Thanks again. I'm going to give this a try. BTW a nicer way to format the time display is: time,5,0,-1,5,l,"dddd, MMMM d, yyyy "," hh:mm:ss  tt"

Now another question. I want to display the date and time in different fonts. Why doen't this work?

time,5,0,-1,5,l,"dddd, MMMM d, yyyy "
changefont,tahoma,12,b
time,120,0,-1,5,l," hh:mm tt"

Thanks for taking the time to help.

ya1950
Title: time command question
Post by: arbitrajeu on October 24, 2003, 09:24:53 AM
Quote from: ya1950Why doen't this work?

time,5,0,-1,5,l,"dddd, MMMM d, yyyy "
changefont,tahoma,12,b
time,120,0,-1,5,l," hh:mm tt"
The reason is that you missed out the comma after the date format in the first line and the comma before the time format for the second.  You must include these even if you don't want to display them.  True to form, I haven't tried these, but try:

time,5,0,-1,5,l,"dddd, MMMM d, yyyy",
changefont,tahoma,12,b
time,120,0,-1,5,l,,"hh:mm tt"
Title: time command question
Post by: ya1950 on October 24, 2003, 09:40:33 AM
Again, thank you very much for your help. Those commas certainly did the trick!

I really appreciate your help.

ya1950