Information générale
Catégorie:
Codage, syntaxe et commandes
I would use a__gen10[1,2]. I don't know if it makes a difference as a property, but in general using the () can confuse VFP because it thinks it's a function. But, yes, just use that as the name of the form property. Then it's visible anywhere in your form, just like any form property.
One problem you may run into is that I don't know if it will like redimensioning the array if it's a form property. You'll have to try it to see because I've never tried it.
You don't need to declare its scope if it's a property, but if you decide to go the variable route, you should. If you only need the array in the _same method_ as it's defined, you can make it LOCAL. If you need it in the whole form, I think you have to make it PUBLIC. (Remember to RELEASE it). I haven't had any luck with PRIVATE variables in forms unless it's defined in a program that calls the form.
Hope that makes sense. :)
Michelle
>so under form new property would I just type in a__gen10(1,2) and it should dimension size correctly? Would I want to declare the array private or local if I want to use the array in same form? Thanks for answering back
>
>
>Nick Patel
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement