Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Compute how many years,months,days
Message
De
29/10/2004 09:24:53
 
 
À
29/10/2004 07:36:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 5
Divers
Thread ID:
00955191
Message ID:
00955751
Vues:
16
thisform.text3.Value= alltrim(str(numyear))+ ' - ' + alltrim(str(nummonth)) + ' - ' + alltrim(str(numday))


>hi,
>ok thanks for advice,
>
>i need another things ,how i can put year,month and date at my thisform.text3.value as under
>
>SET DATE TO british
> a = (thisform.text1.value)
> b = (thisform.text2.value)
>
>NumYear = Year(b)-Year(a)
>NumMonth = Month(b)-Month(a)
>NumDay = Day(b) - Day(a)
>
>If NumDay < 0
>NumMonth = NumMonth - 1
>Numday = (Gomonth(a,1)-Day(Gomonth(a,1)) - a )+ Day(b)
>EndIf
>If NumMonth < 0
>NmYear = NumYear - 1
>NumMonthi = Abs(NumMonth)
>EndIf
>
>? NumYear, NumMonth, NumDay
>
>&&&thisform.text3.Value=numyear+nummonth+numday &&&
>
>
>thanks
>best regards.
>m.qasem
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform