christ77000
XLDnaute Occasionnel
Bonsoir à tous je débute en VBA et je n'arrive pas à insérer un contrôle sur l'existence des feuilles dans ce code. Si un utilisateur clic plusieurs fois sur le bouton de création de feuille ca bloque. Merci pour votre aide.
PS c'est mon premier post.
Sub Creation_IT6_par_nom()
Dim DerLig As Long, i As Integer
DerLig = Feuil2.Range("D" & Rows.Count).End(xlUp).Row
Application.ScreenUpdating = False
For i = DerLig To 29 Step -1
Sheets("IT6").Copy after:=Feuil2
ActiveSheet.Name = Feuil2.Cells(i, 4)
Next i
Application.ScreenUpdating = True
End Sub
PS c'est mon premier post.
Sub Creation_IT6_par_nom()
Dim DerLig As Long, i As Integer
DerLig = Feuil2.Range("D" & Rows.Count).End(xlUp).Row
Application.ScreenUpdating = False
For i = DerLig To 29 Step -1
Sheets("IT6").Copy after:=Feuil2
ActiveSheet.Name = Feuil2.Cells(i, 4)
Next i
Application.ScreenUpdating = True
End Sub