Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ListView Control
Message
De
06/04/2000 08:41:40
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00356070
Message ID:
00356204
Vues:
55
Charles,

Try this:

With Thisform.mylistview
For i = 1 To 5
.ColumnHeaders.Add(, , "Column" + Str(i))
EndFor
For ii = 1 To 5
oListItem = .ListItems.Add(, , "Item" + Str(ii))
For iii = 1 To 4
oListItem.SubItems(iii) = "Subitem" + Str(iii)
EndFor
EndFor
EndWith

>Hi All!

>I am experiencing problems regarding the listview control. I am trying to >build an "Explorer" type of window using a treeview and a listview. THe >problem is that i cannot seem to add the correct sub-items in the listview. I >get a different result. When I tried in VB, it works fine, but in VFP, >different result. My code reads:

>With Thisform.mylistview
>For i = 1 To 5
>.ColumnHeaders.Add(, , "Column" + Str(i))
>EndFor
>For ii = 1 To 5
>.ListItems.Add(, , "Item" + Str(ii))
>For iii = 1 To 4
>** next line of code causes a syntax error
>.ListItems.Item(ii).ListSubItems.Add(, , "Subitem" + Str(iii))
>EndFor
>EndFor
>EndWith
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform