Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Different values of variables
Message
De
02/08/2005 04:42:32
 
 
À
02/08/2005 04:39:40
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 6 SP5
OS:
Windows '98
Network:
Windows 98
Database:
Visual FoxPro
Divers
Thread ID:
01037733
Message ID:
01037739
Vues:
24
Hey You are right Tore, I didn't notice thzt wild use of the command ! :-)
>Hi Tariq,
>
>just a word as advise. Only use alltrim when you really need it, which means practically never! In this code snippet you can remove all the alltrims!
>
>
>
>>Dear Experts
>>
>>
>>store space(10) to mn1,yr1,dd2,cvar1, mn12,yr12,dd22,cvar12,curmon
>>store 0 to lnMonths,lnMonths2,lnMonths3
>>Select year
>>SCATTE MEMV
>>dd1=dtoc(M.b_date) && 01-07-2005 type D
>>mn1=alltrim(substr(dd1,4,2)) && separate month
>>yr1=alltrim(right(dd1,4))    && separate year
>>dd2=alltrim(mn1)+alltrim("-")+alltrim(yr1) && month & year
>>
>>dd12=dtoc(M.e_date) && 30-06-2006 type D
>>mn12=alltrim(substr(dd12,4,2))&& separate month
>>yr12=alltrim(right(dd12,4))   && separate year
>>dd22=alltrim(mn12)+alltrim("-")+alltrim(yr12) && month & year
>>
>>
>>Without Exe the values of variable dd2 and dd22 are
>>
>>Dd2 =”07-2005”
>>Dd22=”06-2006”
>>
>>In Exe the values of variable dd2 and dd22 are
>>
>>Dd2 =”07-7-05”
>>Dd22=”06-6-06”
>>
>>Why values of dd2 and dd2 are different in exe and without exe.
>>
>>Please help
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform