Combobox et listindex : erreur 380
Bonjour, j'ai une erreur lorsque je charge un combobox avec le code suivant :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
|
derLigne = Worksheets("Parametres").Range("e65536").End(xlUp).Row
For j = 3 To derLigne
If ActiveWorkbook.Sheets("Parametres").Cells(j, 5).Value = Me.ListView1.ListItems(i).ListSubItems(4).Text Then
if ActiveWorkbook.Sheets("Parametres").Cells(j, 6).Value - 1= 0 then
frmEcranSaisie.ComboBox1.ListIndex = 0
Else
frmEcranSaisie.comboBox1.ListIndex = ActiveWorkbook.Sheets("Parametres").Cells(j, 6).Value - 1
End If
End If
Next j
End If
Next |
J'ai alors une erreur d'exécution 380 : impossible de définir la propriété ListIndex. Valeur de propriété non valide.
A quoi cela est-il du ? Quelqu'un peut-il m'aiguiller ? Par avance merci