Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Assigning SCATTER named properties
Message
 
 
À
06/10/2001 10:40:15
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:
00565149
Vues:
24
This message has been marked as the solution to the initial question of the thread.
See corrections in bold below

< snip >
>AMEMBERS(laTemp1, loTemp1, 1 )
>
>FOR nX = 1 TO ALEN(laTemp1)
>IF TYPE('loTemp1.' + laTemp1[nX])#'U') .AND. ;
>  TYPE('loTemp2.' + laTemp1[nX])#'U')
>     lcMacro = 'loTemp1.' + laTemp1[nX] + 'loTemp2.' + laTemp1[nX]
>     &lcMacro
>ENDIF
* 1 as a 3rd parameter creats two-dimentional array. 
* To get properties only don't pass 3rd parameter at all. 
AMEMBERS(laTemp1, loTemp1 )  

FOR nX = 1 TO ALEN(laTemp1)
   * laTempArray holds properties of loTemp1. 
   * There's no need to check if they exist again
  IF TYPE('loTemp2.' + laTemp1[nX])<>'U')
        *You dont need macro substitution here, name expression'll work just fine
        STORE EVAL('loTemp2.' + laTemp1[nX]) TO  ('loTemp1.' + laTemp1[nX])
  ENDIF
ENDFOR
>But doesn't work..
>
>Any tips, or a easier way to fix the problem ?
>
>Thanks in advance..
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform