Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
10 numbers
Message
De
09/09/2008 05:05:19
 
 
À
09/09/2008 05:00:48
Lutz Scheffler (En ligne)
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows 2008 Server
Database:
MS SQL Server
Divers
Thread ID:
01345962
Message ID:
01345988
Vues:
13
You just proved what we already knew, that nothing is impossible in VFP. :-)

>C'm on,
>
>it might not be everybodys way, but this is foxpro
>
>#DEFINE SCAN IF
>#DEFINE FOR
>#DEFINE ENDSCAN ENDIF
>
>CREATE CURSOR murks (id_no c(10), no i)
>
>APPEND BLANK
>
>
>SCAN FOR LEN(ALLTRIM(id_no))==10 AND CHRTRAN(ALLTRIM(id_no),"1234567890","")==""
> REPLACE no WITH 111
>ELSE &&error
> REPLACE no WITH 1
>ENDSCAN
>LOCATE
>
>#UNDEFINE SCAN
>#UNDEFINE FOR
>#UNDEFINE ENDSCAN
>
>?no
>
>
>Agnes
>>Have you ever seen the syntax Scan-else-Endscan? It's new to me. The bottom line is that it will give an error, and even if VFP would not catch the error, the Else statement would never execute since the scan already excluded those records.
>>
>>>Why not?
>>>
>>>no # id_no
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform