Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
StrictDate in a Text Endtext Clause
Message
De
26/12/2009 04:43:32
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01440641
Message ID:
01440674
Vues:
39
>>Hi all,
>>
>>i want a strict date in a text endtext clause ;
>>
>>it 's possible ?
>>
>> m.dtest = DATE()
>>
>>
>> TEXT To m.testclause NOSHOW TEXTMERGE PRETEXT 15
>>
>><< m.dtest >> 
>>
>>ENDTEXT
>>
>>
>>Thank in advance
>
>Bernhart,
>
>
>********************************************************************
>*  Description.......: DateToStr - creates a strict date string from date
>*  Calling Samples...:
>*  Parameter List....: tdDate
>********************************************************************
>function DateToStr
>lparameter tdDate
>local lcReturn
>if empty(m.tdDate)
>	lcReturn='{}'
>else
>	lcReturn="{^" + (transform(dtos(m.tdDate), "@R 9999-99-99")) + "}"
>endif
>return m.lcReturn
>
>
>
> TEXT To m.testclause NOSHOW TEXTMERGE PRETEXT 15
>
><< DateToStr(m.dtest) >> 
>
>ENDTEXT
>


This looks familiar to me : ="{^" + (transform(dtos(m.tdDate), "@R 9999-99-99")) + "}"


this one is even shorter Message ID: 1432165
transf(dtos(m.d), '@R {^####/##/##') + '}'
Gregory
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform