Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to tell if a listbox item is disabled?
Message
De
08/01/1997 04:27:55
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00016664
Message ID:
00016724
Vues:
63
>I have found that the old 2.6 method of disabling a specific item in a listbox ("\" + text) still disables
>an item in a 5.0 listbox. Once disabled though, how, in code does one recognize a disabled item? The "\" is not part of the text in a listbox item and .Enabled if for the entire listbox not a specific item.

As far as I can see, you don't know something is disabled.

As you say, the "\" is not returned as part of the .list[] property so you can do things like .list[.listindex] = .list[.listindex] to remove the disabled flag which will always work.
Similarly .list[.listindex] = "\"+.list[.listindex] will always work without adding more and more "\" characters to the value.

It's quite tricky the way it is...


Why do you want to know if something is enabled?
Surely if it's not enabled the user can't have chosen it?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform