Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Substract month from month
Message
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:
01035596
Message ID:
01035603
Vues:
14
This message has been marked as the solution to the initial question of the thread.
SET CENTURY ON
SET DATE TO MDY
lnMoveMonths = -3 && move forward or backward
lcDelimiter = "-" && SET("Mark") 
lcTextboxValue = "02-2005"
lcTextboxValue = DTOC(GOMONTH(DATE(VAL(SUBSTR(lcTextboxValue, ATC(lcDelimiter, lcTextboxValue) + 1)), VAL(LEFT(lcTextboxValue, ATC(lcDelimiter, lcTextboxValue) -1)), 1), lnMoveMonths))
lcTextboxValue  = LEFT(lcTextboxValue, 2) + "-" +RIGHT(lcTextboxValue, 4)
?lcTextboxValue
>Dear Sir,
>
>I have a character type textbox="02-2005" && February 2005
>I want to substract 3 months from it.
>
>Please elp
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform