Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Have no selecteditem in treeview..
Message
De
11/07/2003 07:07:46
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Titre:
Have no selecteditem in treeview..
Divers
Thread ID:
00809131
Message ID:
00809131
Vues:
66
Hi,

How can I set the selecteditem to nothing or set it to the root
when i have a treeview control?

Currently all elements are added at the root level. I though about adding a "root" node at the top but this might confuse the users.

In this situation there is no way to not select an item.

I managed to partially solve the problem by placing this code in the click event:

IF Thisform.otree.SelectedItem.Key==thisform.lcLastSelectedItemKey AND !EMPTY(thisform.lcLastSelectedItemKey)
FOR lnI=1 TO Thisform.otree.nodes.Count
Thisform.otree.Nodes[lnI].Selected=.F.
ENDFOR
thisform.lcLastSelectedItemKey=""
*Thisform.otree.SelectedItem.Key=""
ELSE
thisform.lcLastSelectedItemKey=Thisform.otree.SelectedItem.Key
ENDIF

When I click off the current node (to the white space for example) the node
no longer appears selected which is what I want but the SelectedItem property is still set to the node..

Any Ideas?

BR
Tim
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform