[DUG] hour / minute component

John Bird johnkbird at paradise.net.nz
Fri Feb 5 10:11:58 NZDT 2010


I don't think there is any real standard way to enter either times or time intervals - what I do is use a straight edit box which allows several alternate formats and convert the entry on the onexit event,

eg I can allow times like 1:10pm to be entered as 

13:10
1:10pm

or time intervals can be entered as eg for 1 hour 30 mins

1:30:00
1:30     (may need to be smart here, you may want sometimes to interpret this as 1 min 30 sec)
1h30

Means you have to write your own convert text to time routine, but can make it really smart and easy to enter text into.  Never much used mask edit as I found it too puzzling to set up formats for cases like this, the help was not much help.

Sunbird (Thunderbird calendar add-on) has a rather neat way to enter times - it gives a list of times through the hour that can be expanded or shrunk to get more detail - but its not standard.

I think even if there was a component I might hesitate to use it for the reasons of "Will this make it hard to upgrade my Delphi version?"

John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listserver.123.net.nz/pipermail/delphi/attachments/20100205/cd3fa536/attachment.html 


More information about the Delphi mailing list