Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Getting 1st Item in ListBox by code
Message
De
04/05/2012 16:48:22
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01543189
Message ID:
01543196
Vues:
59
>>Hi Gang!
>>
>>I want to be able to programatically select the 1st item in a ListBox.
>>
>>e.g.
>>
>>In the ListBox are Dog,Cat,Bird,Hamster
>>
>>I want the program to go get the 1st item.. which is Dog.
>>
>>What would you code to this?
>>
>>Thanks
>
>Let me add to this.... what I wanted to say was that I wanted to get programatically the same result as if I clicked on the control and selected the 1st item.
>
>So I want to "click" on the item and then do an ListBox.InteractiveChange.

Set the list's ProgrammaticChange to call InteractiveChange (or better, add a custom AnyChange method and have PC and IAC both call it).

Then:

This.ListIndex = 1

sets the value and fires ProgrammaticChange.

Tamar
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform