Private Sub Workbook_SheetBeforeDoubleClick(ByVal Sh As Object, ByVal Target As Range, Cancel As Boolean)
Dim ncol%, Sh1 As Worksheet, Sh2 As Worksheet, ShDest As Worksheet, i&, memo
ncol = 20 'nombre de colonnes
Set Sh1 = Sheets("Situation ") 'pourquoi un espace ???
Set Sh2 = Sheets("Entrepôt")
If Sh.Name = Sh1.Name Then Set ShDest = Sh2
If Sh.Name = Sh2.Name Then Set ShDest = Sh1
If ShDest Is Nothing Then Exit Sub
If Sh.Cells(Target.Row, 3) <> 1 Then Exit Sub
i = 5
While ShDest.Cells(i, 2) <> "": i = i + 1: Wend
With Sh.Cells(Target.Row, 2).Resize(, ncol)
ShDest.Cells(i, 2).Resize(, ncol).FormulaR1C1 = .FormulaR1C1
.ClearContents 'RAZ*
memo = .Offset(1).CurrentRegion.Resize(, ncol).FormulaR1C1 'mémorise
.Resize(UBound(memo)).FormulaR1C1 = memo 'décale vers le haut
.Offset(UBound(memo)).ClearContents 'efface la dernière ligne
End With
Application.Goto ShDest.Cells(i, 2) 'facultatif
End Sub