Sub EssaiiltreEtInputBox()
Dim newbook As Workbook
Dim intLigneDebutSelection As Integer
Dim intLigneFinSelection As Integer
Dim intLigneDuRemplacementConfirme As Integer
Dim intLigneRenseignee As Integer
Dim rngPlageSelectionnee As Range
With wksTrameConfRemp
.Unprotect
.Range(.Range("C6"), .Range("M1000")).ClearContents
End With
With wksBD
.Activate
.Unprotect
On Error Resume Next
Set rngPlageSelectionnee = Application.InputBox(Prompt:="Veuillez s?lectionner des cellule de la demande ? envoyer", Type:=8, Default:="")
On Error GoTo 0
End With
Application.ScreenUpdating = False
With rngPlageSelectionnee
On Error Resume Next
intLigneDebutSelection = .Row
intLigneFinSelection = intLigneDebutSelection + .Rows.Count - 1
On Error GoTo 0
End With
With wksBD
On Error Resume Next
.Range(.Range("C" & intLigneDebutSelection), .Range("M" & intLigneFinSelection)).SpecialCells(xlCellTypeVisible).Copy
On Error GoTo 0
End With
Set newbook = Workbooks.Add
With wksTrameConfRemp
.Unprotect
.Range("C6").PasteSpecial
.Range(.Range("C6"), .Range("M6").Offset(intLigneFinSelection - intLigneDebutSelection, 0)).EntireColumn.AutoFit
.Copy before:=newbook.Sheets("Feuil1")
End With
Application.ScreenUpdating = True
End Sub