>Hi all:
>
>I have a date field on a report which could display as follows:
>
>
6/27/02 or 6/5/02 or 6/27/2002 or 6/5/2002
>
>I would like the date to be displayed as follows:
>
>
06/27/02 or 06/27/2002
>06/05/02 or 06/05/2002
>
>The format is dependent on the user machine's settings. Padl() is for strings only or can it be used here also.
>
>Thank you all.
PADL() (as well as PADR() and PADC() ) is not for strings only. It automatically converts numerics and dates.
Try:
?padl(date(),20,"xx")
?padl(1457.08,20,"xx")
However, I am not sure how PADL() may help you to convert the dates like 6/5/02
Why would your VFP date fields contain such a data? To me it's more like a SET DATE issue.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro
"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison