Bonjour, j'ai ecris un petit truc pour faire un calcul un peu lourd a la main, et j'ai oublié d'enregistrer la macro , du coup je le réécris mais ce coup là j'ai une erreur "Else sans If" et je n'arrive pas a comprendre pourquoi , ça doit être évident pourtant mais...?

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Sub dure()
Dim i As Integer
 
For i = 2 To 641
 
If Cells(i, 9) <> "" Then Cells(i, 11) = Cells(i, 12)
ElseIf Cells(i, 8) <> "" Then Cells(i, 11) = Cells(i, 13)
ElseIf Cells(i, 7) <> "" Then Cells(i, 11) = Cells(i, 14)
ElseIf Cells(i, 6) <> "" Then Cells(i, 11) = Cells(i, 15)
ElseIf Cells(i, 5) <> "" Then Cells(i, 11) = Cells(i, 16)
ElseIf Cells(i, 4) <> "" Then Cells(i, 11) = Cells(i, 17)
ElseIf Cells(i, 3) <> "" Then Cells(i, 11) = Cells(i, 18)
Else: Cells(i, 11) = "SANS FU"
 
End If
 
Next i
 
End Sub