Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Declare a cursor?
Message
De
23/12/1999 16:05:20
 
 
À
23/12/1999 15:30:27
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00308067
Message ID:
00308204
Vues:
47
>>Ed,
>>
>>>>>>can you start a cursor name w/ a numeric value?
>>>>>
>>>>>Nope, or form properties/methods and object names, or field names.
>>>>
>>>>It's a FP limitation. You MUST start from letter. Try this:
>>>>
>>>
>>>or an _
>>
>>You can use _, but it's mostly for system variables, like _mline or _tally.
>
>>Huh? Where did it ever say that in any of the VFP docs? It may be a naming >standards decision for your development group, but it's always been an >acceptable prefix for fields as long as name collisions don't occur.
>
>That is exactly right. There's nothing in VFP stopping you from doing it, or even suggesting that you shouldn't. But I have heard in the past (mainly from my schooling in C++) that I should only use _ to start a variable name for system variables. However, I haven't heard of anything in ANY language that makes this a manditory restriction
>

Yep, again it's a naming convention, and _ is used by some of the name manglers that link things togther in C++. The main thing here is that VFP doesn't enforce any standard naming convention on you, even if you do really, really silly things like using reserved names or even system variable names for field names (I can show you some really horrible FPDOS code with a field named _PCOLNO that had all sorts of interesting side effects in combination with macro expansion used with reports built using @...SAY). You'll find VFP violates some of its own rules for itself - look at the structure of the LABELS DBF that comes with VFP, and you'll find a bunch of reserved words as field names. The docs tell you that you have to start a name with an alpha character or an underscore IAC.

>Paul A. Busbey
>I.S. Department
>Sparagowski & Associates
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform