Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Macro substitution in object references?
Message
De
08/04/2005 10:23:08
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Macro substitution in object references?
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01002613
Message ID:
01002613
Vues:
61
In order to populate a form with a variable number of labels and spinners I am trying to do something like the following:
_variety = "Cortland"
SELECT item,descrip FROM inventory WHERE variety = _variety INTO CURSOR _itemlist

ncnt = 1
SCAN
	ccnt = ALLTRIM(STR(ncnt))
	mlbl = "lbl"+ccnt
	mspn = "spn"+ccnt
	thisform.AddObject(mlbl,"label")
	thisform.AddObject(mspn,"spinner")
	thisform.&mslbl.caption = _itemlist.item + " " + _itemlist.descrip
	thisform.&mslbl.visible = .t.
        ncnt = ncnt + 1

endscan
Obviously, the macro substitution doesn't work in this instance. Can anybody offer me a nudge in the right direction to achieve what I'm trying to do?

Thanks in advance!

Andrew
On a CLEAR day you can see forever.
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform