bonjour,

j'ai essayé d'optimiser mon code d'origine en ce qui va suivre mais je n'ai aucun résultat ni message d'erreur

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
If Cadre1.Value = 2 And Cadre2.Value = 3 And Cadre3.Value = 3 Then
table = "Table_1"
tables = "Table_1a"
ElseIf Cadre1.Value = 2 AndCadre2.Value = 3 And Cadre3.Value = 7 Then
table = "Table_2"
tables = "Table_2a"
ElseIf Cadre1.Value = 3 And Cadre2.Value = 3 And Cadre3.Value = 3 Then
table = "3"
tables = "3a"
For i = 1 To 40
res = Nz(DLookup("Chm", "tables", "[ID] = " & i))
Next i
merci