Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
List box problem...
Message
De
26/08/2002 16:39:19
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
List box problem...
Divers
Thread ID:
00693827
Message ID:
00693827
Vues:
52
Hi All,

I am trying to store and then restore the selections in a multi-select list box. I have the code to store the selections working fine. Basically, I stored an underscore delimited string of the 'key' values. Now, I want to take this string and restore the multi-selections, but only the last item I set to selected is selected.

Here is my code:
LPARAMETERS cObjName, cSelected

LOCAL oObj AS ListBox, i

oObj = EVALUATE("This."+cObjName)

FOR i = 1 TO oObj.ListCount
	IF ALLTRIM(oObj.ListItem[i,2]) $ cSelected
		oObj.SelectedID[i] = .T.
	ENDIF
ENDFOR

RETURN
Any help would be apreciated.

BOb
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform