Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Field Names
Message
De
13/11/1997 19:49:33
 
 
À
13/11/1997 19:31:16
Jon Griffin
Computer Nerds, Inc.
St. George, Utah, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Divers
Thread ID:
00060163
Message ID:
00060166
Vues:
23
Can you be a little more specific? What did you try to do? What's the exact code line that takes the view name (is it a property in your class)? What code line generates the error?

Assuming that the view name is kept in a property MyClass.ViewName:

To take a list of fields:

*-- Replace the spaces in the view name with "_"
lcViewName = chrtran(This.ViewName," ","_")
*-- Take the structure of the view
= AFields(laFieldList,lcViewName)

Now, the laFieldList array contains the info about the structure of your view. For more details on this array, look at AFIELDS() function in the Help.

The view must be opened when you do this.

Vlad


>I am trying to create a class that uses a view that is not hard-coded. I can't seem to get the view name out of a variable.
>
>I am writing a generic parsing program that takes fields out of a view and writes them to a text file in a very strange mainframe format. I want ( in the best possible OO manner) to just have a class that the user(programmer) can drag onto a form and set the view name. When I do this I get an error from the form (I think) that it either can't find the property or something to that effect.
>
>I know this has probably been discussed but if someone can point me in the right direction.
>
>Also, (I come from 7 years of C++), does VFP not have a useful manual on thier OO parts? It seems that they only prefer to use OOP for controls.
>
>Thanks,
>Jon Griffin
>
>
>Check out www.salsablanca.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform