>>>>>Hi everybody,
>>>>>
>>>>>I decided to update my VFPStart program to allow automatically insert my initials and date in the short format, e.g.:
>>>>>
>>>>>* Insert modidate
>>>>>on key label f3 keyboard 'Nadya Nosonovsky '+ttoc(datetime()) plain
>>>>>on key label Alt+U keyboard 'Updated:NN: '+dtoc(date()) plain
>>>>>
>>>>>However, I want to to have dates like 02/02/02, etc. , is where a simple way besides substr() or changing set century back and forth?
>>>>
>>>>
STRTRAN(dtoc(date()), "200", "0")
for the next 7 years.
>>>
>>>
>>>Not a general one, anyway, I think, this would be enough for now :)
>>>I removed / because separators could be different for different set date formats
>>
>>Here's generic. For time add + " " + Time()
Substr(Dtos(Date()),5,2) + "/" + Right(Dtos(Date()),2) + "/" + Substr(Dtos(Date()),3,2)
>
>I knew it, but it's too mach typing... :)
>================================================
>BTW, I better change my key to assign on ALT+Q key.
>
>Is it possible to do the same in a macro?
Why don't you use COB Editor Extensions (CEE) for VFP 6.0 (4 March 1999) from
http://www.cobsystem.com/freetool.htm ? It saves a lot of typing and you can code your own shortcuts.
--sb--