Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Assigning SCATTER named properties
Message
De
08/10/2001 04:31:43
 
 
À
06/10/2001 13:32:40
Ing. T.R.M. Pluym
Pluym Elektronics Bv
Hulst, Pays-Bas
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00565148
Message ID:
00565387
Vues:
20
>With the macro (&) in stead of the EVAL(), it works just fine..
>
>Thanks again...

While your method of copying an object of a SCATTER NAME variety will work with the &, I find it to be too slow. What I do is:

using the table that the scatter name object was created from, create an array of the structure using AFIELDS(), create a cursor from that array, APPEND a BLANK record, GATHER NAME from the original SCATTER NAME object to the new cursor, and then do a SCATTER NAME to a new object, effectively creating a copy. More steps, but much faster.
LOCAL aStruct[1]
SELECT table
SCATTER MEMO NAME oFirst
AFIELDS(aStruct)
CREATE CURSOR temp FROM ARRAY aStruct
APPEND BLANK
GATHER MEMO NAME oFirst
SCATTER MEMO NAME oSecond
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform